<?xml version="1.0"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">

<channel>
	<title>Planet Mandriva</title>
	<link>http://planetmandriva.zarb.org/</link>
	<language>en</language>
	<description>Planet Mandriva - http://planetmandriva.zarb.org/</description>

<item>
	<title><![CDATA[Pascal Terjan: The most unusable branch locator I have seen so far]]></title>
	<guid>http://fasmz.org/~pterjan/blog/?date=20100902#p01</guid>
	<link>http://fasmz.org/~pterjan/blog/?date=20100902#p01</link>
	<description><![CDATA[<p>Today I wanted to locate an HSBC branch in London, close to either the office or my home. Thanks to HSBC I got upset before 8.</p>
<p>That starts fine, they have an "interactive map" or allow you to enter your postcode. Unfortunately they use only the beginning of the postcode (SW in my case) and then <a href="http://www.hbeu1.hsbc.com/ukservices/branchlocator/area.asp?area=sw&type=&flag=true">list you many towns</a> in this area. Using the map stops at the same level. Then you click one of them (I should do all of them as I don't know some which may be close) and get <a href="http://www.hbeu1.hsbc.com/ukservices/branchlocator/town.asp?town=1322&type=&flag=true">No branch exists in ...</a></p>
<p>Is it so hard to list the closest ones from the given postcode or place them on a map? And what about just removing from the list the places without a branch?</p>]]></description>
	<pubDate>Thu, 02 Sep 2010 07:29:04 +0000</pubDate>
</item>
<item>
	<title><![CDATA[Eugeni Dodonov: KDE Hacking]]></title>
	<guid>http://dodonov.net/blog/?p=769</guid>
	<link>http://dodonov.net/blog/2010/09/01/kde-hacking/</link>
	<description><![CDATA[<p>So, after a take on <a href="http://dodonov.net/blog/2010/05/06/gnome-hacking/">Metacity</a> , I just went ahead and implemented the same quick workspace switching feature for KDE (namely, kwin) &#8211; with great help from Nicolas Lécureuil (a.k.a. Neoclust) of course!</p>

<p>Basically, it works essentially like the same feature in xfwm4 &#8211; when you switch to a different workspace via a keyboard shortcut, and press the same shortcut again while on this workspace, it will bring you back to the previous one. So you can press ctrl-f2 to switch to from workspace 1 workspace 2, and when you press ctrl-f2 again kwin will recognize that you want switch back, to whatever workspace you were before, and will do it. An extremely handy quirk which I cannot live without anymore <img src="http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif" alt=":)" class="wp-smiley" /> .</p>

<p>I have to assume that I have never ever coded anything for KDE until yesterday, but it turned out to be extremely simple. KDE has its flaws, its infrastructure with billions of libraries and processes everywhere is hard to understand, but I actually was surprised on how easy it was.</p>

<p>So, without further words, the patch for kdebase4-workspace which adds this functionality follows (sorry for the formatting, but kde has some very long lines of code..):</p>

<pre><code>diff -p -up kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.cpp.switchback kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.cpp
--- kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.cpp.switchback 2010-09-01 09:10:02.000000000 -0300
+++ kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.cpp    2010-09-01 09:21:13.000000000 -0300
@@ -184,6 +184,7 @@ void KWinDesktopConfig::init()
     connect( m_ui-&gt;popupHideSpinBox, SIGNAL(valueChanged(int)), SLOT(changed()));
     connect( m_ui-&gt;desktopLayoutIndicatorCheckBox, SIGNAL(stateChanged(int)), SLOT(changed()));
     connect( m_ui-&gt;wrapAroundBox, SIGNAL(stateChanged(int)), SLOT(changed()));
+    connect( m_ui-&gt;switchBackBox, SIGNAL(stateChanged(int)), SLOT(changed()));
     connect( m_editor, SIGNAL(keyChange()), SLOT(changed()));
     connect( m_ui-&gt;allShortcutsCheckBox, SIGNAL(stateChanged(int)), SLOT(slotShowAllShortcuts()));
     connect( m_ui-&gt;effectComboBox, SIGNAL(currentIndexChanged(int)), SLOT(changed()));
@@ -252,6 +253,8 @@ void KWinDesktopConfig::defaults()

     m_ui-&gt;wrapAroundBox-&gt;setChecked( true );

+    m_ui-&gt;switchBackBox-&gt;setChecked( false );
+
     m_editor-&gt;allDefault();

     emit changed(true);
@@ -285,6 +288,9 @@ void KWinDesktopConfig::load()
     KConfigGroup windowConfig( m_config, "Windows" );
     m_ui-&gt;wrapAroundBox-&gt;setChecked( windowConfig.readEntry&lt;bool&gt;( "RollOverDesktops", true ) );

+    // Quick switching back to previous desktop
+    m_ui-&gt;switchBackBox-&gt;setChecked( windowConfig.readEntry&lt;bool&gt;( "SwitchBackDesktops", false ) );
+
     // Effect for desktop switching
     // Set current option to "none" if no plugin is activated.
     KConfigGroup effectconfig( m_config, "Plugins" );
@@ -341,6 +347,9 @@ void KWinDesktopConfig::save()
     // Wrap Around on screen edge
     KConfigGroup windowConfig( m_config, "Windows" );
     windowConfig.writeEntry( "RollOverDesktops", m_ui-&gt;wrapAroundBox-&gt;isChecked() );
+    //
+    // Quickly back to previous desktop
+    windowConfig.writeEntry( "SwitchBackDesktops", m_ui-&gt;switchBackBox-&gt;isChecked() );

     // Effect desktop switching
     KConfigGroup effectconfig( m_config, "Plugins" );
diff -p -up kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.ui.switchback kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.ui
--- kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.ui.switchback  2010-09-01 09:09:59.000000000 -0300
+++ kdebase-workspace-4.5.65svn1165394/kwin/kcmkwin/kwindesktop/main.ui 2010-09-01 09:59:02.000000000 -0300
@@ -7,7 +7,7 @@
     &lt;x&gt;0&lt;/x&gt;
     &lt;y&gt;0&lt;/y&gt;
     &lt;width&gt;572&lt;/width&gt;
-    &lt;height&gt;310&lt;/height&gt;
+    &lt;height&gt;334&lt;/height&gt;
    &lt;/rect&gt;
   &lt;/property&gt;
   &lt;layout class="QHBoxLayout" name="horizontalLayout"&gt;
@@ -141,6 +141,16 @@
          &lt;/property&gt;
         &lt;/widget&gt;
        &lt;/item&gt;
+       &lt;item&gt;
+        &lt;widget class="QCheckBox" name="switchBackBox"&gt;
+         &lt;property name="whatsThis"&gt;
+          &lt;string&gt;Enable this option if you want to remember and recall previous desktop when switching via keyboard shortcuts. E.g., if you switched to desktop 2 by pressing its shortcut, pressing it again while on desktop 2 will bring you back to the previous desktop.&lt;/string&gt;
+         &lt;/property&gt;
+         &lt;property name="text"&gt;
+          &lt;string&gt;Remember and recall previous desktop when switching via keyboard shortcuts&lt;/string&gt;
+         &lt;/property&gt;
+        &lt;/widget&gt;
+       &lt;/item&gt;
        &lt;item&gt;
         &lt;widget class="QGroupBox" name="groupBox_3"&gt;
          &lt;property name="title"&gt;
diff -p -up kdebase-workspace-4.5.65svn1165394/kwin/kwin.kcfg.switchback kdebase-workspace-4.5.65svn1165394/kwin/kwin.kcfg
--- kdebase-workspace-4.5.65svn1165394/kwin/kwin.kcfg.switchback    2010-09-01 09:10:56.000000000 -0300
+++ kdebase-workspace-4.5.65svn1165394/kwin/kwin.kcfg   2010-09-01 09:16:20.000000000 -0300
@@ -41,6 +41,7 @@
   &lt;entry key="ShadeHover" type="Bool" /&gt;
   &lt;entry key="GeometryTip" type="Bool" /&gt;
   &lt;entry key="RollOverDesktops" type="Bool" /&gt;
+  &lt;entry key="SwitchBackDesktops" type="Bool" /&gt;
   &lt;entry key="FocusStealingPreventionLevel" type="Int" /&gt;
   &lt;entry key="Placement" type="String" /&gt;
   &lt;entry key="AutoRaise" type="Bool" /&gt;
diff -p -up kdebase-workspace-4.5.65svn1165394/kwin/options.cpp.switchback kdebase-workspace-4.5.65svn1165394/kwin/options.cpp
--- kdebase-workspace-4.5.65svn1165394/kwin/options.cpp.switchback  2010-09-01 09:12:09.000000000 -0300
+++ kdebase-workspace-4.5.65svn1165394/kwin/options.cpp 2010-09-01 09:26:40.000000000 -0300
@@ -87,6 +87,8 @@ unsigned long Options::updateSettings()

     rollOverDesktops = config.readEntry("RollOverDesktops", true);

+    switchBackDesktops = config.readEntry("SwitchBackDesktops", false);
+
     legacyFullscreenSupport = config.readEntry( "LegacyFullscreenSupport", false );

 //    focusStealingPreventionLevel = config.readEntry( "FocusStealingPreventionLevel", 2 );
diff -p -up kdebase-workspace-4.5.65svn1165394/kwin/options.h.switchback kdebase-workspace-4.5.65svn1165394/kwin/options.h
--- kdebase-workspace-4.5.65svn1165394/kwin/options.h.switchback    2010-09-01 09:12:07.000000000 -0300
+++ kdebase-workspace-4.5.65svn1165394/kwin/options.h   2010-09-01 09:22:14.000000000 -0300
@@ -215,6 +215,11 @@ class Options : public KDecorationOption
          */
         bool rollOverDesktops;

+        /**
+         * whether or not quick switching back to previous desktop is allowed via keyboard shortcuts
+         */
+        bool switchBackDesktops;
+
         // 0 - 4 , see Workspace::allowClientActivation()
         int focusStealingPreventionLevel;

diff -p -up kdebase-workspace-4.5.65svn1165394/kwin/workspace.cpp.switchback kdebase-workspace-4.5.65svn1165394/kwin/workspace.cpp
--- kdebase-workspace-4.5.65svn1165394/kwin/workspace.cpp.switchback    2010-05-20 08:42:10.000000000 -0300
+++ kdebase-workspace-4.5.65svn1165394/kwin/workspace.cpp   2010-09-01 10:10:02.000000000 -0300
@@ -95,6 +95,7 @@ Workspace::Workspace( bool restore )
     , desktopGridSize_( 1, 2 ) // Default to two rows
     , desktopGrid_( new int[2] )
     , currentDesktop_( 0 )
+    , prevDesktop_( 0 )
     , desktopLayoutDynamicity_( false )
     , tilingEnabled_( false )
     // Unsorted
@@ -1403,6 +1404,15 @@ bool Workspace::setCurrentDesktop( int n
     StackingUpdatesBlocker blocker( this );

     int old_desktop = currentDesktop();
+
+    // Eugeni: are we trying to switch back to previous desktop?
+    if (options-&gt;switchBackDesktops &amp;&amp; (old_desktop == new_desktop ) &amp;&amp; (prevDesktop() &gt; 0) )
+        {
+        // go back to previous desktop
+        new_desktop = prevDesktop();
+        kDebug(1212) &lt;&lt; "Switching back to " &lt;&lt; new_desktop;
+        }
+
     if (new_desktop != currentDesktop() )
         {
         ++block_showing_desktop;
@@ -1413,6 +1423,7 @@ bool Workspace::setCurrentDesktop( int n
         ObscuringWindows obs_wins;

         currentDesktop_ = new_desktop; // Change the desktop (so that Client::updateVisibility() works)
+        prevDesktop_ = old_desktop;

         for( ClientList::ConstIterator it = stacking_order.constBegin();
             it != stacking_order.constEnd();
diff -p -up kdebase-workspace-4.5.65svn1165394/kwin/workspace.h.switchback kdebase-workspace-4.5.65svn1165394/kwin/workspace.h
--- kdebase-workspace-4.5.65svn1165394/kwin/workspace.h.switchback  2010-08-11 07:08:13.000000000 -0300
+++ kdebase-workspace-4.5.65svn1165394/kwin/workspace.h 2010-08-31 23:34:01.000000000 -0300
@@ -245,6 +245,10 @@ class Workspace : public QObject, public
          */
         int currentDesktop() const;
         /**
+         * @returns The ID of the previous desktop.
+         */
+        int prevDesktop() const;
+        /**
          * Set the current desktop to @a current.
          * @returns True on success, false otherwise.
          */
@@ -314,6 +318,7 @@ class Workspace : public QObject, public
         QSize desktopGridSize_;
         int* desktopGrid_;
         int currentDesktop_;
+        int prevDesktop_;
         QString activity_;
         bool desktopLayoutDynamicity_;

@@ -1142,6 +1147,11 @@ inline int Workspace::currentDesktop() c
     return currentDesktop_;
     }

+inline int Workspace::prevDesktop() const
+    {
+    return prevDesktop_;
+    }
+
 inline int Workspace::desktopAtCoords( QPoint coords ) const
     {
     return desktopGrid_[coords.y() * desktopGridSize_.width() + coords.x()];
</code></pre>]]></description>
	<pubDate>Wed, 01 Sep 2010 13:42:44 +0000</pubDate>
</item>
<item>
	<title><![CDATA[Shlomi Fish: Is the web becoming fragmented?]]></title>
	<guid>http://community.livejournal.com/shlomif_tech/52195.html</guid>
	<link>http://community.livejournal.com/shlomif_tech/52195.html</link>
	<description><![CDATA[<p>
<a href="http://www.catonmat.net/">Peteris Krumins</a> 
<a href="http://www.catonmat.net/blog/node-js-knockout-competition">writes:</a>
</p>

<blockquote>
<p>
So I participated in the 48 hour Node.js Knockout competition together with
James Halliday and Joshua Holbrook. Our team was called Dark Knights and we
created an online chess application called Node Chess.
</p>

<p>
…
</p>

<p>
Oh, and it <b>works only [on] Chrome. Ancient-browsers-please-be-gone!</b>
</p>

</blockquote>

<p>
My question is: how can you call Firefox, whose 
<a href="https://developer.mozilla.org/devnews/index.php/2010/07/23/firefox-3-6-8-now-available-for-download/">latest stable release was on the 23 of July
this year</a> and which has perfectly usable and nightly builds <b>ancient</b>?
</p>

<p>
It is highly possible that due to the recent hype surrounding HTML 5 and its
mutually partial implementation by the different browsers, that we are entering
a situation where many sites or demos will only work on particular browsers.
This didn't start with Peteris' post - naturally. Previously, someone from
<a href="http://www.isoc.org.il/">the Israeli Internet Society</a>
referred me to some demos that said required a WebKit-based browser, and during
a presentation about HTML 5 in an "Alphageeks" meeting, the presenter had
to use three different browsers, because all the features he wanted to
demonstrate did not work on all of them. And this is without taking
the account
<a href="http://arstechnica.com/open-source/news/2010/06/mozilla-evangelist-criticizes-apple-html5-showcase.ars">Apple's
block of non-"Apple Safari" browsers from its HTML 5 demos</a>
and the fact that <a href="http://www.spice-space.org/">www.spice-space.org</a>
obnoxiously redirects you to 
<a href="http://www.spice-space.org/noscript.html">"This site requires JavaScript" page</a> if JavaScript is disabled, and many other sites do not function
properly without JavaScript enabled.
</p>

<p>
And as a commenter on Reddit for a web demo said, while the
<a href="http://en.wikipedia.org/wiki/Demoscene">demoscene</a> people have
been trying to produce demos that utilise the most out of the computer's
resources, the web demos have come to waste a lot of resources in creating
anachronistic demos, whose only selling point is that they run inside
a browser. As <a href="http://www.joelonsoftware.com/articles/FB4.5.html">Joel
on Software notes</a>: <q>Combined with the speed and responsiveness from Ajax,
FogBugz has <i>almost</i> reached the level of speed and fluidity of my dry 
cleaner's DOS 2.0 character mode database application. And that's pretty darn 
responsive for a web app.</q>
</p>

<p>
Are we headed into another "Best viewed with Netscape 2.0", "Best viewed with
Internet Explorer 4.0", etc. era of web fragmentation, because we opened
the Pandora box of HTML 5? As for me, if I were a judge on that competition
that Peteris took part of, I would fail his project due to not being capable
of running on my ancient browser. 
</p>]]></description>
	<pubDate>Tue, 31 Aug 2010 11:44:48 +0000</pubDate>
</item>
<item>
	<title><![CDATA[Shlomi Fish: Perl Debugger Tip: A Session Startup File]]></title>
	<guid>http://community.livejournal.com/shlomif_tech/51785.html</guid>
	<link>http://community.livejournal.com/shlomif_tech/51785.html</link>
	<description><![CDATA[<p>
Here's a small Perl debugger tip: in order to have a file whose commands
will be executed at the start of the debugging session (for example in order
to get to a certain point in the code) - a session startup file, similar
to gdb's <tt>--command=cmds.gdb</tt> flag - one can do the following:
</p>

<p>
First of all write a file with the debugger commands you want (let's call it
<tt>cmds.perldb</tt>) and then when inside the perl debugger say:
</p>

<pre>
source cmds.perldb
</pre>

<p>
This will execute all the commands.
</p>

<p>
I noticed that after a while the perl debugger stores it inside the history
(assuming you're using Term-ReadLine-Gnu), so you can recall it with
<tt>s</tt> and then pressing the <tt>history-search-forward</tt>
and <tt>history-search-backward</tt> that were set up (Mandriva assigns
them to Page Up and Page Down).
</p>

<p>
Enjoy and I'm sorry for having neglected this blog for a long while!
</p>]]></description>
	<pubDate>Wed, 25 Aug 2010 19:12:41 +0000</pubDate>
</item>
<item>
	<title><![CDATA[Stéphane Téletchéa: Your own local repository for Mandriva]]></title>
	<guid>http://steletch.free.fr/spip.php?article65</guid>
	<link>http://steletch.free.fr/spip.php?article65</link>
	<description><![CDATA[<div class="rss_chapo"><p>Nowadays, RPMs are mostly downloaded from internet. Since accessing RPMs from the hard drive is still faster, we will see in this little article some tips and tricks to use a local repository on your system, either using an entire mirror of the distribution or using the DVD edition as a local source.</p></div>
		<div class="rss_texte"><h3 class="spip">Setting up your own mirror</h3>
<p>The easiest way is to use <strong>rsync</strong> to keep your local mirror up-to-date, for instance to grab the entire tree for the 2010 Spring release under the i586 architecture:</p>
<div class="spip_code" dir="ltr"><code>su -<br /> mkdir /var/ftp<br /> exit (no need to be super-user for the command hereafter)<br /> rsync -rav --delete-after rsync://distrib-coffee.ipsl.jussieu.fr/pub/linux/MandrivaLinux/official/2010.1/i586/ /var/ftp</code></div>
<p>The initial download time will depend of your internet connection (beware, if you have a bandwith constraint, this command will download around 25 GB of data...).</p> <p>If you use the mirror seldomly you can issue the command manually, otherwise you can put it in a cron task (see <a href="http://en.wikipedia.org/wiki/Cron" class="spip_out" rel="nofollow">http://en.wikipedia.org/wiki/Cron</a>).</p> <h3 class="spip">Using the DVD as an additionnal media</h3>
<p>The iso image is lying on your hard disk, waisting space. A good way of using it is to <i>mount</i> it as a loop:</p>
<div class="spip_code" dir="ltr"><code>su -<br /> mount -o loop /path/to/mandriva-linux-free-2010-spring-i586.iso /var/ftp</code></div>
<p><strong>Do not forget to change <i>/path/to/</i> for the real pathway to the iso file.</strong></p> <p>If you wish to do it permanently, add this entry to the <i>/etc/fstab</i> file:</p>
<div class="spip_code" dir="ltr"><code>/path/to/mandriva-linux-free-2010.1-i586.iso /var/ftp iso9660 ro,loop=/dev/loop0 0 0</code></div>
<h3 class="spip">Adding the mirror/iso to your local media definitions</h3>
<p>You will now <strong>add</strong> the media definitions to the list of existing media (it will not erase them):</p>
<div class="spip_code" dir="ltr"><code>su -<br /> urpmi.addmedia --distrib /var/ftp</code></div>
<p>You can now safely install programs. If the desired version is present locally, it will install it from the local hard drive, otherwise <strong>urpmi/rpmdrake</strong> will pick it from the internet.</p> <p>If you do not have other internet media, use <a href="http://easyurpmi.zarb.org/" class="spip_out" rel="nofollow">http://easyurpmi.zarb.org</a> to have them automatically installed for you.</p></div>]]></description>
	<pubDate>Wed, 25 Aug 2010 08:31:58 +0000</pubDate>
</item>

</channel>
</rss>
