## Saturday, December 19, 2009

### More KDE4 rants

Seeing that I apparently hit a nerve for some people with my last post, here is the next thing that really annoys me every day in KDE4.

Those ugly passive pop-ups that appear on the display near the area where you have configured the "system tray" to be on the panels. From the beginning they were an example of uglyness. After quite some time they at least stopped to be drawn one over the other, so they are no longer totally unusable, but they still are not pretty.
One example: most of them are too small, so that the text they should show me gets cut off and I have to guess what the system wants to tell me.

As much as I detest GNOME, their unobtrusive notifications in the lower right corner are much more stylish and less disturbing than the KDE4 ones.

And it is not QT's fault: a proprietary application like skype, using QT, can do it in almost the same way as GNOME, so it is definitely possible.

### Programs using the root window considered obsolete in KDE4

See https://bugs.kde.org/show_bug.cgi?id=219249. Unfortunately this means that my wife and kids will not get upgraded to KDE4 once I'll replace their 11.0 installations but will probably get GNOME instead. Because no xsnow (for my wife) and no xpenguins (for my kids) - that's just not an option.

## Tuesday, December 08, 2009

### png2pdf with pdflatex

Recently I needed to create a PDF from two scanned pages and found out that there was no png to pdf converter on openSUSE. Or at least I could not find it. The "png2pdf" project that I found on sourceforge when searching the net was already abandoned by its author and, as its successor, "bmeps", needed the very obscure and hard to package "dklibs" package.

Then I remembered that I had used some TeX template to create my slides for FOSDEM etc over the last years, and that they included an openSUSE logo in PNG format.

5 minutes later I came up with:
\documentclass[a4paper]{minimal}\usepackage{graphicx}\usepackage{geometry}\geometry{left=-0.8cm,textwidth=21.7cm,top=0cm,textheight=29.6cm}\begin{document}\includegraphics{page1.png}\newpage\includegraphics{page2.png}\end{document}

Which did its job reasonably well. Don't ask me why I needed that weird \geometry{} setting - I know next to nothing about TeX. But it produced a nice PDF with both scanned pages, so it was good enough for me ;)

## Wednesday, December 02, 2009

### Recovering your data from clicfs (aka openSUSE Live USB stick)

Today I wanted to recover some of the data I had saved on my openSUSE 11.2 live USB stick, just to find out that it was not really trivial. It actually included reading the manpage of coolo's clicfs, so I'll write it down here to save others the hassle ;)

I assume the normal live USB stick layout (dd'ed the ISO which was treated with isohybrid to the stick, then added a second partition with fdisk, if I plug in the stick it turns up as /dev/sdb1 and /dev/sdb2) for the following.

First, create the mountpoints and mount the "normal" ISO image:
# mkdir /mnt/iso /mnt/root /mnt/clic# mount /dev/sdb1 /mnt/iso -oro

You'll now find the clicfs container on the mounted ISO fs:
# hexdump -C /mnt/iso/openSUSE-kde-11.2-livecd-kde-read-only.i686-2.8.0 |head -n 100000000 43 4c 49 43 30 32 0b 00  00 00 66 73 64 61 74 61 |CLIC02....fsdata|

Second, mount the clicfs:
# clicfs -c /dev/sdb2 /mnt/iso/openSUSE-kde-11.2-livecd-kde-read-only.i686-2.8.0 /mnt/clic/# ls -l /mnt/clic/total 0-rw-r--r-- 1 root root 3891789824 Jan 1 1970 fsdata.ext3

Third, just loop mount the fsdata.ext3 file:
# mount /mnt/clic/fsdata.ext3 /mnt/root/ -oloop

That's it. You can now access all data that you stored on your Live stick under /mnt/root.
If you only want to have the "original" contents of the Live system, without the stuff you saved, then just replace the "-c /dev/sdb2" with "-m 128" which will use a ramdisk for the "write" part of the filesystem instead of the second partition on the stick. (Don't just leave off the "-c ..." without adding "-m", this got me a hanging mount later when I was trying the loop mount. I was able to resolve it with a brave "umount -f /mnt/clic" and then "killall -9 clicfs" though).

To get rid of it, just unmount it in reverse order:
# umount /mnt/root# umount /mnt/clicfs# umount /mnt/iso