While I have used and appreciated many applications which are considered part of the Gnome desktop suite, my preference has always been to use the KDE desktop and over the long reign of KDE-3 I came to appreciate how easy it was to set my KDE desktop and applications up the way I want them to be.
If you are not familiar with Slackware, please note that Slackware ships software as it is written by the upstream developers. Your distribution's developers may have changed or added to your distro's KDE so what I write here may not apply to you or may not be necessary for you to bother with.
Be forwarned.
Your old ~/.kde from KDE-3.5.X configurations may not work correctly in KDE4. I have noted this to be the case with konsole, kate and konqueror. If you are like me and keep ypur /home/~ intact from one upgrade/install to the next it is best to rename or make a backup of your old ~/.kde and start off in KDE4 with a new automatically generated one..
Once you are up and running you can copy over the importants stuff like konqueror's bookmarks.
I am dual booting Slack-12.2 and Slack-Current. I always set up a work station with /home as well as /usr/local and /opt on their own partitions. This way if I re-install or something nasty happens, I don't loose years of accumulated files whether I need them or indeed even know they are there. This has also made it very easy to share my home directory if I'm dual booting a stable and current version of slackware when I only had to contend with one version of KDE/Qt.
To avoid messing up my /home/~/.kde in 12.2 when running current and conversely current with 12.2 I have put together a script which symlinks a .kde directory to either a .kde3 or .kde4 in my /home/~ directory depending on which version has been installed on the system running..
After doing the above, I rebooted into /current. Once up and running in KDE4, I copied over some things from my .kde3 directory such as my konqueror bookmarks and .kde3/share/apps/kab, kabc, and kmail. I left most things in .kde3/share/config alone and just recognfigured in KDE4 apps as required.
Once this was all set up I could boot into 12.2 or /current but use the same /home directory without mixing my KDE3 and KDE4 settings or blowing my Desktop (directory) in KDE3 on KDE4.
Creating icons in KDE 4:
Kde 4 does not have desktop icons anymore. If you don't believe me look
here. I spend allot of time on the command line but I also like to have some icons on top of my desktop for scripts I have written, software I have compiled from source that haven't come icon and desktop ready. While I use
Midnight Commander extensively I also like to have icon links to directories containing shared video and audio files. Things have changed in KDE 4.2 and I can't create these icons the same way I did in KDE 3.X
I brought this up on a KDE mailing list and some folks came back saying that there were icons on their KDE-4.X desktop and that they could still create icons by right clicking on the desktop etc. Yes they probably can and do. However, that is because they are looking at a folder in folderview. There is now a folderview widget that allows the users to put a transparent directory ..... er folder on the desktop with the content of that folder becoming icons on the desktop as in the screenshot linked to the thumbnail below. According a
KDE 3 to KDE 4 tutorial this is the suggested work around for people wanting the old KDE 3 desktop icon functionality starting with KDE 4.2.to the
 |
As you can see in the screenshot, there is a ghost folder of /usr/share/applications showing icons with names ending with the extension, desktop. Any one of these can be dragged directly onto the desktop if you wanted it as a desktop icon and this could be done from Konqeror of Dolphin, i.e. you don't need to have a folder in folderview to have icons on your desktop as all the other icons on my desktop clearly illustrate.
However, this does not help me if there is something I want to run from a desktop icon but there has been no icon installed with the package for if I want an icon for a script I wrote or a frequently accessed URL. For example, I have a simple script named audcap that I use to capture sound passing through my sound card. I want an icon so if I'm streaming off the net or watching TV I can hit the icon and capture the audio as soon as possible. I hit the icon, get a kdialog pop up, enter the how long to record for and hit OK to close the window. Very easy and quick but I need an icon on my desktop and I dont want to use folderview.
I can create icons in KDE 4 the old fashioned KDE 3 way by right clicking in a folder, or I can just do it in an editor if I know the .desktop file format plus the path to the executable and icon image I want to use. In my case I have created a folder /usr/local/share/applications and the .desktop (icon) files I create for my own use are saved in there from which I can drag them to my desktop. Alternatively I cold have temporarily put that folder on my desktop in folderview and create the icon using the right click - create - link to application or the right click - create - text file methods
If you hit the thumbnail above you will see a screenshot of my desktop with my /usr.local/share/applications directory in folder view. Note that in the top left hand corner there is an icon named Audcap. I have created this icon for my script audcap in this directory using the "right click method" and the text content of this desktop file looks like this:
|
[Desktop Entry]
Comment[en_US]=
Comment=
Exec=
GenericName[en_US]=
GenericName=
Icon=/usr/local/share/icons/eyechina.png
MimeType=
Name[en_US]=/usr/local/bin/audcap
Name=/usr/local/bin/audcap
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
X-DBUS-ServiceName=
X-DBUS-StartupType=
X-KDE-SubstituteUID=false
X-KDE-Username=
|
|
The audcap desktop file above will do the trick but after looking at the audacity desktop file that installed in /usr/share/applications when I installed the slackpac I have opted for a simpler format based on audacity.desktop which after editing looks a bit more complete and works just fine.
|
[Desktop Entry]
Encoding=UTF-8
Name=Audcap
GenericName=Audio Capture
Comment=Capture audio using arecord
Icon=/usr/local/share/icons/eyechina.png
Exec=/usr/local/bin/audcap
Terminal=false
Type=Application
Categories=AudioVideo;
|
|
The .desktop files I create can be used just like any other .desktop the come with KDE-4.2 either on the desktop, in the Start menu seletions or in the Quicklaunch widget on my panel. There is probably an API or some other documentation floating around on the net which discusses this in greater detail but this is all I really need to know to create icons for use on our machines.
Network scanning with skanlight
I was not able to get Skanlite to work after intstalling KDE-4.2. It could not see my networked skanner which I thought a bit odd since I had no problem scanning with Xsane and skanlite was also supposed to be gui frontend for sane.
It seemed that everytime I ran
skanlite either from the command line or from a menu all I got was a popup telling me it could not find a device. When I chased up the documentation on the web I found that Skanlite could be told which scanner device to use on the command line like this
skanlite -d [scanner device]
I don't know about other networks or networked scanners but if I run the command sane-find-scanner no network scanner is found. However, if I run the command scanimage -L, my network scanner will be correctly identified.
rick@rick:~$ scanimage -L
device `net:192.168.1.4:hpaio:/usb/PSC_2350_series?serial=MY493C10JCKJ' is a Hewlett-Packard PSC_2350_series all-in-one
I'd quess that skanlite parses the ouput of sane-find-scanner to create a selection list of scanner device(s) and so it will not open for me because sane-find-scanner does not list my networked scanner. However, I can open skanlite and scan if I run this command in konsole:
skanlite -d net:192.168.1.4:hpaio:/usb/PSC_2350_series?serial=MY493C10JCKJ
That's fine and dandy but it that's cli and a rather unmemorable command so if I want to take the easy way out its a matter of editing the skanlite in kmenuedit entry so that the command entry looks like this:
scanlite %u -d net:192.168.1.4:hpaio:/usb/PSC_2350_series?serial=MY493C10JCKJ
Skanlite will open from the menu and since I know all I need to know about creating and editing .desktop files, I can edit my /usr/shar/applications/skanlite.desktop like as below:
[Desktop Entry]
Type=Application
Exec=skanlite -caption "%c" %i -d
net:192.168.1.4:hpaio:/usb/PSC_2350_series?serial=MY493C10JCKJ
Icon=skanlite
X-DocPath=skanlite/index.html
Terminal=false
Name=Skanlite
I don't know about other distros but here there is not much in skanlite.desktop to begin with and if I really wanted it as an icon on my desktop I'd have to nominate one because there does not seem to be one provided by KDE. Not a big deal since Xsane has more features and if I'm just scanning an image to work with in Gimp, I can scan it in Gimp.
Maplayerthumbs
If you are wondering where the thumbnails have gone in Konqueror and Dolphin first make sure that you have enabled previews in the View menu. That will give you previews for images but not for video files.
To get preview thumbnails of video files you will need to install
mplayerthumbs. There has been a change in KDE 4 from a xine based thumbnail generator to an mplayer based one which is supposed to be a bit quicker. Unfortunately Slackware does not ship with mplayer so it stands to reason it won't ship with mplayerthumbs.
Having originally installed kde-4 on Slackware-12.2 where KDE 3 aps should still run, my first thought was to check for a ready made package but there were no recent versions of mplayerthumbs available and so I downloaded version 1.2 which has been fixed to work with KDE-4.2 according to its changelog, compiled it according to the README, built a slackpac and installed.
I will discuss compiling mplayerthumbs in greater detail below.
My one complaint about mplayethumbs is that it grabs a frame to use as a screenshot too early into the video which doesn't work very well with older movies especially if they are in black and white. There is a gui configurator for mplayerthumbs named, of all things, mplayerthumbsconfig However, there is not much configuration available and I haven't yet found a way to get mplayethumbs to grab a frame from a little further back in the stack.
|
 |
| Before |
After |
Compiling mplayer in /current as of 07/04/2009
Slackware ships with xine but does not ship with mplayer.
Consequently, I will not have video thumbnails in kde$ on /current unless I install mplayer which, if I am now going to run current on my workstation, will also be required for other things as well such as encoding with mencoder.
Software from the most recent stable release may or may not run correctly on /current but I took a punt and installed the additional libraries, codecs, etc. I had used with
mplayer on Slack-12.2 and tried compiling mplayer using the 12.2 slackbuild from
http//slackbuilds.org.
My first attempt at building an
mpayer slackpack failed because
DirectFB was required. As per instructions on the website, I obtained the source and compiled DirectFB as per my notes below:
rick@rick:~# git clone git://git.directfb.org/git/directfb/core/DirectFB.git
To compile DirectFB cd into the directory and do the following
rick@rick:~# ./autogen.sh --prefix=/usr --enable-multi
Run make, then install into a build directory:
root@rick:~# make install DESTDIR=/root/build
and then do the usual to build a slack pack
Once I had built and installed DirectFB, I was able to build
mplayer using the 12.2 slackbuild script from
www.slackbuilds.org and install it on my /current box.
Using cmake to compile KDE-4 appications
Cmake has been selected as KDE build system starting with KDE4 and I had an opportunity to familiarise myself with it when building mplayerthumbs..
I'm not going to get very technical. Suffice to say that you need two directories to compile a package with
cmake, one where you have untarred the source and another to build the package the cmake way. Follow my notes below to see how I built
mplayerthumbs with
cmake. The slack-desc was generated with the Slack Description Creator found at
http://www.linuxpackages.net/slackcreator.php.
Untar source code. In my case it is: 41180-mplayerthumbs-1.2.tar.gz
The README talks about setting a bunch environmental variables. Don't worry about it.
Cmake is the standard for building packages for kde4 and it needs a build directory
mkdir mplaythumbs-build
Next cd into mplayerthumbs-build and run the cmake command with it pointing to the directory with
the untarred source code:
cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=release ../mplayerthumbs-1.2
Next make a build directory for building the slackpack and install into it:
make install DESTDIR=../build-mplayerthumbs
Then create the slackpack and do the usual
mplayerthumbs: mplayerthumbs 1.2
mplayerthumbs:
mplayerthumbs: Mplayerthumbs is used in kde4 to create thumbnails of videos. It is
mplayerthumbs: supposed to be faster than the xine based thumbnail creator used
mplayerthumbs: in kde3
mplayerthumbs:
mplayerthumbs:
mplayerthumbs:
mplayerthumbs:
mplayerthumbs:
mplayerthumbs: Package Created By: Rick Miles
Using KDE3 software in KDE4 a.k.a. installing avidemux
The short of it is you cannot run any application that depends on Qt3 which means just about anything written for and run on KDE3 unless you install the kde3-compat slackpacks found in ./current/extra. If you don't have those packages installed read on.
I have been using
gopdit to edit dvb-t programs I save to disk for a very long time. However, it was written with Qt3 and so it will not compile in KDE4 until it is re-written with Qt4.
Gopdit is a fast and very basic program ideal for doing just the one thing I want to do with a video editor, cut the unwanted bits out of mpeg-ps videos, and it was one of the reasons why I hesitated moving to KDE4. Another reason for not moving was the absence of an mplayer to run on /current but with that resolved I began looking around for an alternative to gopdit.
I settled on using
avidemux with versions >=2.4 written for Qt4. However, I had a cmake error when trying to build it:
make[2]: *** [po/avidemux_pt_BR.qm] Error 1
make[1]: *** [po/CMakeFiles/qmfiles.dir/all] Error 2
make: *** [all] Error 2
and rather than spend time troubleshootuing the error I decided to take a punt on an avidemux-qt4-2.4.4 slackpack found in the 12.2 repository at
http://slacky.eu. It turns out that there was one dependency listed that I did not have on board so I also downloaded and installed
aften from slacky.
My first attempt at running avidemux CLI with the command avidemux2_qt4 told me that I was missing libartsc.so.0, which turned out to belong to arts, a package no longer required by KDE4 but present in my 12.2 install
rick@rick:~$ ls -l /mnt/hda6/lib | grep libartsc.so.0
lrwxrwxrwx 1 root root 17 2009-04-03 02:05 libartsc.so -> libartsc.so.0.0.0*
lrwxrwxrwx 1 root root 17 2009-04-03 02:05 libartsc.so.0 -> libartsc.so.0.0.0*
-rwxr-xr-x 1 root root 19424 2008-09-11 14:42 libartsc.so.0.0.0*
so I copied libartsc.so.0.0.0 over into /usr/lib on my /current install and then symlinked libartsc.so.0 to it with the command
ln -s /usr/lib/libartsc.so.0.0.0 /usr/lib/libartsc.so.0.
After "borrowing" libartsc.so.0.0.0 from 12.2 avidemux opened up and worked just fine with the exception that the window was too tall and controls on the bottom extended off screen. Forcing a specific opening size in the Window Specific Settings fixed this problem.
Running Gopdit compiled on KDE3 on KDE4
OK, if you read the previous section you know I set up avidemux on my /current install without having the kde3-compat packages installed but then I figured no matter how smart and pretty avidemix is, gopdit is leaner (read quicker) and meaner even if it is uglier and anyway if I can borrow one library from /usr/lib on my 12.2 install, why not another.
When I try to run
gopdit compiled on Slackware-12.2 from the command line in /current I get an error message saying that gopdit can't find
libqt-mt.so.3. This library file does not exist in /usr/lib of my /current install but it can be found on my 12.2 install:
rick@rick:~$ ls -l /mnt/hda6/lib/ | grep libqt-mt
lrwxrwxrwx 1 root root 18 2009-04-03 02:06 libqt-mt.so -> qt/lib/libqt-mt.so*
lrwxrwxrwx 1 root root 20 2009-04-03 02:06 libqt-mt.so.3 -> qt/lib/libqt-mt.so.3*
lrwxrwxrwx 1 root root 22 2009-04-03 02:06 libqt-mt.so.3.3 -> qt/lib/libqt-mt.so.3.3*
lrwxrwxrwx 1 root root 24 2009-04-03 02:06 libqt-mt.so.3.3.8 -> qt/lib/libqt-mt.so.3.3.8*
A search through /usr/lib on my version of /current does not come up with anything close to the name of those files . Indeed it appears that everything in Qt4 comes with mix of upper amd lower case, e.g.
libQtGui.so.4.5.0, so I figured it would be safe enough to copy over
/usr/lib/qt/lib/libqt-mt.so.3.3.8 file and create a symlinked file
/usr/lib/libqt-mt.so.3 as was the case in 12.2.
rick@rick:~$ ls -l /usr/lib | grep libqt-mt.so.3
lrwxrwxrwx 1 root root 17 2009-04-13 13:00 libqt-mt.so.3 -> libqt-mt.so.3.3.8*
-rwxr-xr-x 1 root root 6958628 2008-02-29 11:04 libqt-mt.so.3.3.8*
Avidemux is a fine piece of software, I'm sure, but it is more than I need and it takes a long time to open a video for editing. Whereas gopdit just opens the video and lets me start editing and even though it has not been re-written for QT4 I can now use it in KDE4. Theres a thumbnail link to a screenshot of gopdit in action on my kde4 desktop below. Hmmmm ... I wonder what else I can get running on this box ...........
Compiling K9copy for KDE4
This is a bit of a non event.
I downloaded version 2.3.1 and using the same cmake procedure discussed above. It compiled without a problem and runs like a champ.