Monday 31 October 2011

Online web-based notes

In a previous blog entry (http://phayz.wordpress.com/2011/04/11/online-and-offline-notes-for-chromeium/) I wrote that I had been trying to find a way of maintaining notes using the Chrom(e|ium) web browser. I wanted to be able to make a note of little bits and pieces of information via my web browser *plus* have these available when I was offline. At the time I settled on the Scratchpad extension because it did what I wanted and had a bonus of keeping notes in sync on Google Docs.

After a little while I stopped using Scratchpad because I didn't like how it looked, nor how it stored the notes on Google Docs. I later tried the SpringPad web service but this was much more than I wanted and offered an offline option only if using Chrome (or Chromium). I didn't want my choice limited by the browser I was using at the time. For the moment I am using a web-based service named SimpleNote (http://simple-note.appspot.com) because it's very simple but offers searching of notes. It doesn't work offline unfortunately but I usually need these notes when the PC is on and I have Internet connectivity most of the time. If I am desperate I could try one of the third-party applications which allow for notes to be exported.

Once again I'm happy at the moment with my choice. I may change my mind again, so be prepared for future blog entries on the topic. :D

Friday 28 October 2011

HOWTO: Rotate a video using ffmpeg

Note:I am using Linux and have not tested this on other operating systems, so your results may vary.

I recently received a video from someone with a request to post it to a video hosting site. It all sounded simple until I found that the video had been recorded using an iPad in landscape mode so when I played the video the image was rotated. Before posting it I was going to have to rotate the video so that playback looked normal but how was I going to do that?

I first considered a video editor but the ones I considered had too many dependencies so I continued my search and eventually found a solution here: http://stackoverflow.com/questions/3937387/rotating-videos-with-ffmpeg, which gave instructions on using ffmpeg's "transpose" feature to rotate the video.

For my task here's the command line I used. This is to entered as one line, but may be appear wrapped in your browser:
ffmpeg -i <input_video_filename> -vf "transpose=1" -r 30 -sameq -acodec copy <output_video_filename>

The "transpose" function is one of ffmpeg's many video filters which, according to the ffmpeg man page is used to "Transpose rows with columns in the input video and optionally flip it." Below is a list of other transpose parameters and what they do. For full details, refer to the transpose video filter section of ffmpeg's man page for details of the necessary values.


0 = 90CounterCLockwise and Vertical Flip (default)
1 = 90Clockwise
2 = 90CounterClockwise
3 = 90Clockwise and Vertical Flip


Note: In this example I used three additional parameters:

  • "-acodec copy" parameter, which instructs ffmpeg to copy the audio, not process it again (Note: Thanks to a comment on this blog entry from Tim;

  • "-sameq" parameter so that the video's original quality was not lost during the rotation because without it ffmpeg degraded quality;

  • "-r 30" to maintain a framerate of 30 frames per second.

Tuesday 13 September 2011

Zoom zoom in GNOME 3's Overview

When you press the Windows (AKA "Super") key, GNOME presents the Overview, a thumbnail view of all the open windows. By accident I discovered that if you hover the mosue cursor over any of the thumbnails and move the mouse's scroll button, you can zoom in and out the thumbnail. I'm not sure in what version of GNOME 3 this was introduced, nor what you would use it for my I thought I would mention it here anyway. :D

How to run a Chromium "snapshot" build on Fedora 15

First, a little background: although Chromium is kindly packaged by Tom Callaway (a maintainer of a LOT of Fedora packages), when I installed it I had several problems occur. Instead I decided to try running a Chromium snapshot and it seemed simple enough:

Download the latest snapshot build (in Zip file)

  1. Unzip it to ~/bin

  2. Run the chrome binary contained


When I tried this, though, it complained that it couldn't load a BZip2 library. Chromium was looking for the library by a different name so I created a symlink in /lib64:
ln -s libbz2.so.1.0.6 libbz2.so.1.0

 

WARNING - WARNING - WARNING: Although the next step(s) won't harm your system I have worked out a better method of getting "Open with..." functionality working for Chromium. I will update this post with those details when I have time.

My next problem was that when I tried to use the "Open with..." functionality anywhere, a new instance of Chromium was started with a separate window and it complained that it couldn't access my profile. I guess it didn't like two instances running at the same time. As an ugly hack I installed the packaged version of Chromium, then:

  1. Renamed /bin/chromium-browser to chromium-browser.OLD

  2. Created a symlink /bin/chromium-browser to ~/bin/chrome-linux/chrome


So far everything's working as I want it to but only time will tell if I have been successful. In the future I expect I'll revert to the packaged version but for now this method is without errors and that's what I need.

Saturday 25 June 2011

GNOME 3 tip: remove title bar from maximised windows

Note: This tip was presented by the Web Upd8 site but I wanted to mention it here in case people hadn't already seen it there.

In a standard GNOME 3 windows have a titlebar which contains only the window's title and a close button. To maximise the amount of vertical space available, the tip presented on the Web Upd8 site changes the theme so that maximised windows no longer have a title bar. Since the name of the application also appears in the panel at the top of the screen, there's no information lost there. And even though the close button is no longer visible, you can easily access the window controls menu by pressing [Alt] + [Space].

If you have a netbook or simply want a little extra vertical space, try this tip for yourself.

Wednesday 8 June 2011

Searching for the "right" application

As I often do, I have recently been trying to find just the right application to meet my needs. My latest search is for a "communications client", whatever that means. I am usually online when I use my PC but there are also times, usually when I'm writing the Frugalware Linux newsletter, that I am not so I need offline access.

Like most people, I use both online and offline communications:

  • Online - instant messaging: usually IRC;
  • Offline - mail and RSS feeds.

For offline access I believe a traditional email client would probably suit since I use an IMAP server and so can download select IMAP folders. I have tried several email clients and the results so far are summarised below. In this case I was trying to find an application which had several features, which I know goes against the Unix way but that's my preference in this case.

Thunderbird

* Mail

It looks good, works well in sync-in select IMAP folders, just as I want. Thunderbird's configuration seems more complex than that of most other applications, especially when you have multiple mail accounts. Like all other mail clients, you can easily maintain a list of contacts. In summary Thunderbird works as I expect it to but I can't seem to get comfortable with its user interface with elements that I think take up too much space. I could use it if I need to.

* RSS feeds

Thunderbird works well with RSS feeds, including allowing you to import your RSS feed list.

* Extra features?

Thunderbird can also sync calendars via the Lightning extension so that's a bonus. The only problem here is that Lightning is an add-on, not an integral part of Thunderbird so as I upgrade I need to wait for Lightning's development to catch up. Of course I didn't mention above that I want sync-in of my calendar but if the application can do it I think it's a bonus.

Evolution

* Mail

Same as Thunderbird. Evolution's configuration dialog boxes seem a lot simpler than those of Thunderbird.

* RSS feeds

It seems that there was once an extension for Evolution to allow this but the project appears to be dead. Of course I can use something like Liferea but that means I don't have all my offline communications in one place.

* Extra features?

Evolution offers calendar sync-ing as a native feature and works well with Google Calendar, for example.

Opera

* Mail

I like the look and feel of Opera, user interface and so like its mail interface. I particularly like that you can compose messages in a tab, which it seems none of the other two offer. There are of course reasons for and against this so it's usually a matter of personal taste. What is annoying about Opera is trying to troubleshoot problems with mail sync-ing. It only offers a log file and then only if you manually configured it to do this. Otherwise its error reporting is poor because it doesn't help you find what's wrong. In summary I like Opera a lot but it's not open source. :(

* RSS feeds

Like Thunderbird, RSS feeds appear in Opera's mail panel and are easily managed and read.

* Extra features?

Where Opera is lacking is that there's no calendar sync-ing function, even as an extension. It has several other features that neither Thunderbird nor Evolution offer but they're not really related to this blog post.

 

I haven't yet found the "right" application but I'll keep looking...

Monday 11 April 2011

Online and offline notes for Chrom(e|ium)

I often need to make a note of something when browsing the web and, since my current web browser of choice is Chromium, I have been looking for a suitable extension. I soon discovered Scratchpad, an extension developed by Google. It allows you to keep free-format text notes which are stored locally and, if you choose, synchronise them with a Google Docs account. This looked to do what I wanted but after a little testing I found it annoying because when you click on the extension's icon it appears in a small window in the top right-hand corner of the browser's window. I also found that items I was deleting via the extension were not being deleted from my Google Docs account.

I then started using an extension called Quick Note which offered much the same functionality but synchronised with Diigo, not Google Docs. Later I stumbled across a blog post which revived my interest in Scratchpad because it showed a simple method of having it open in a full tab instead of a tiny window. Since I discovered this tip I have again switched my storage of online and offline notes back to Scratchpad from Quick Note.

Since I plan to store all sorts of information (some would say "rubbish" :P ) via Scratchpad, having a full-content search capability would be useful. The above blog post also listed a solution to this, with Google Docs is used as a custom search engine solely for documents stored via Scratchpad.

At least for the moment I'm very happy with Scratchpad and so will continue to use it. Keep an eye on my blog though, in case I find something I like more. :P

Tuesday 29 March 2011

I think I'm in love...with a GTK theme

Yes, I have to admit it - I love the Murrine-Unity-Carbonite GTK theme. I am often searching for the "perfect" theme but am usually disappointed. I can't recall where I first saw the Murrine-Unity set of themes (Carbonite being the grey version) but it was probably the Gnome Look site. What can I say but it's everything I ever wanted in a theme and more: it's not glossy, menus look good, buttons look good, the GNOME panel looks good, in fact everything looks good to my eyes. I have also tested it under Xfce and it looks good there too! I sometimes get excited (yes, I agree that I should get out and see more of the world) by a theme under GNOME and then find out that it doesn't look quite as good under Xfce. Sign. :(

For the moment I am very happy with this theme and I hope we're together for a long time. That doesn't mean I can't look at other themes, just not while I'm using Murrine-Unity. :)

I hope you like what you see.

Screenshot of Murrine Unity Carbonite GTK theme

Guayadeque - a nice desktop-neutral media player

I have been searching for an audio player which can take the place of Rhythmbox, because I switch between the GNOME and Xfce desktop environments. My main problem has been that I don't know what I am looking for, only what I don't want. :( I have tried all of the GUI audio media players available in the Frugalware repositories. After a long search I am currently using Guayadeque - http://guayadeque.org. It's quite light on dependencies but is very full featured, including support for:

  • Cross-fade

  • Lyrics

  • Downloading album artwork

  • Audio

  • Podcasts

  • Recording


Screenshot of Guayadeque audio player

I may not use an audio player like most people because I usually listen to just one album at a time. Guayadeque suits me but I can't explain just why I like it. Just as different text editors suit different people, the same applies to audio media players. I am beginning to understand just why there are so many media players available on Linux: not everyone's the same. The only thing I now need to do is find an application which allows me to rip tracks from a CD into my preferred format. I'm thinking that a console-based application would be best. When I find one I like I'll report back here.

For the moment, keep on rocking!

Thursday 17 March 2011

My current favourite Chrom(e|ium) extensions

 

Here are the Chrom(e|ium) extensions and apps which I am currently using and the purpose for which I have them installed. This list may not be of use to anyone else but at least if I lose all my extensions I know where to get a list of those I did have installed. :)

I'm trying to keep the list of extensions to a minimum because I know they use memory all the time they're running.

 

Extensions

Scribefire - blog entry writing, which allows for writing entries offline. Since I usually think of stuff I want to blog about while offline, this was an important feature.

App Launcher - provides an icon in the top bar from which I can choose an installed application.

Adblock PLus for Google Chrome - blocks ads. :) I'm still not sure if this is worth having installed but I'll wait and see.

Diigo Bookmark etc... - to bookmark pages of interest. I am experimenting with this extension as a way of bookmarking and storing web pages which I want to read later.

Google Tasks - provides a full-window view of tasks in Google Tasks.

Quickrr World Clock - displays the current time in whatever locations around the world you choose. I use this when chatting in IRC and want to know the local time elsewhere.

RSS Subscription Extension - I use this to subscribe quickly and easly to RSS feeds.

 

Apps

imo - This is basically a link to the imo chat web site which provides a web interface to multiple instant messaging networks.

Quick Note - allows you to store text and images both locally and synchronise with your personal Diigo "library". I am testing this as a way of making notes about stuff that I need to have access to offline.

 

HOWTO: Download Blip.tv content for offline viewing

I was recently reading a post from the official Disqus blog and they mentioned that they had given a talk at Pycon 2011, with the video being available at Blip.tv. I hadn't viewed anything at Blip.tv before and found that the videos are, of course, shown using Flash. I wanted to be able to view them offline and, since I use Chromium as my prefered browser, went looking for an extension would allow me to download them. I couldn't find anything but I did find a bookmarklet which launched a Javascript application which showed the link to the video content, allowing you to download it offline.

I tried the bookmarklet and it worked as advertised but it linked to a web site which displayed ads. I thought "Hey, if all it's doing is finding the link, why can't I do that myself?" So went back to Blip.tv, viewed the source and looked for the link(s) to the video file and entered the link alone in the address bar. This started dispaying the video and only the video in Chromium and I could then right-click on the video and use the "Download" link to save the video file locally.

If anyone has suggestions as to how this might be done better I'm happy to receive comments. I'm just happy that I can download the videos.

Stable is...ummm...stable

I like Frugalware for the fact that you choose between 6-monthly releases with only security updates, or a rolling release. Having the latest packages available is fantastic if you want to get the latest features. I have an anti-Midas touch though, and although I have used 'current' in the past, I need to stay with 'stable'. Every time I switch from stable to current, something goes wrong and my laptop doesn't boot reliably or soemthing which worked before now doesn't work. In those cases I can sometimes work out what went wrong and fix it, or otherwise I reinstall stable.

I don't know for how long I'll be able to resist switching to current but I'm hoping it's a long time. Stable is...ummm...stable. I have only two hardware issues at the moment: wireless doesn't work and nor does my laptop's in-built web cam. I need to get wireless working but I haven't yet put much effort towards this. Otherwise I'm happy because I'm not updating packages daily and so can rely on being productive.

Yay!

Stable is...ummm...stable

I like Frugalware for the fact that you choose between 6-monthly releases with only security updates, or a rolling release. Having the latest packages available is fantastic if you want to get the latest features. I have an anti-Midas touch though, and although I have used 'current' in the past, I need to stay with 'stable'. Every time I switch from stable to current, something goes wrong and my laptop doesn't boot reliably or soemthing which worked before now doesn't work. In those cases I can sometimes work out what went wrong and fix it, or otherwise I reinstall stable.

I don't know for how long I'll be able to resist switching to current but I'm hoping it's a long time. Stable is...ummm...stable. I have only two hardware issues at the moment: wireless doesn't work and nor does my laptop's in-built web cam. I need to get wireless working but I haven't yet put much effort towards this. Otherwise I'm happy because I'm not updating packages daily and so can rely on being productive.

Yay!

Tuesday 8 February 2011

WIP - improving the Frugalware newsletter's production

Soon after starting to write the Frugalware Linux newsletter I realised that some of the tasks I did could be automated. The bug fixes and security announcements are sections that could be automated, for example. The previous newsletter's author had created a PHP script which fully automated the production of the security announcements' table. Since taking over the role I had made only one small change to his script. Several years later I have just started more significant work to automate some aspects of the newsletter's production. Anyone who had been watching me over that time would have thought I was sitting still. There are two things I am working on at the moment: AsciiDoc-ising the newsletter and automating the production of the bugs status section.

AsciiDoc

AsciiDoc is a tool written in Python which takes documents written in a "light" markup language and can convert them into HTML, PDF, ePub and several other formats. We currently use it to produce the official Frugalware documentation. So far the newsletter has been written in HTML and handling the markup gets in the way of writing content. This is very much like the reason CSS was invented and has proven so popular. AsciiDoc not only allows the writer to focus on writing but also makes it possible to publish in formats the author may not have considered before. The conversion of the newsletter has been successful so far, although it hasn't yet been used to produce a published issue. Taking this one step further I am using another feature of AsciiDoc which allows me to have a master document which refers to the various sub-documents. When I run the AsciiDoc tool over the master document, the output is one document which consists of the sub-documents put together. The advantage I have here is that I can write individual pieces, allowing me to focus on smaller pieces at a time. It also means that I can write pieces in advance and quickly assemble several pieces into a completed newsletter.

Automation

I am also working to improve the level of automation in producing the newsletter. I have started on a Bash script to produce the bugs activity section. This is already partially automated because I already use a Bash script but the existing script must be edited every time I want to update the statistics. Results so far have been promising so I hope I'll have this ready in time for the next issue.

I have written this in case readers of the newsletter are interested in the planned improvements. Once this stage of work is done I'd like to review the newsletter's content to see if it can also be improved. Maybe there are areas of Frugalware that readers would be interested in seeing covered? Until more time is available though, the arrangements will have to remain as they are now.

Monday 31 January 2011

AsciiDoc - I think I see the light at the end of the tunnel...

..and I hope it's not a train coming the other way. :P

I am trying to use the AsciiDoc application to produce the Frugalware Linux newsletter. AsciiDoc is a tool which takes text written in a "light" markup language and converts it - via various tools - into formats such as HTML, ePub, DocBook etc. I have only just begun learning about it and I tend to be a slow learner.

I first made the mistake of taking an existing newsletter issue in HTML format and manually converting it to AsciiDoc format. This all looked good when I used the basic AsciiDoc tool to convert it to HTML. However when I tried to do the same using the more sophisticated 'a2x' tool, I got validation error messages. I asked for help on the AsciiDoc Google Groups' group and quickly got help, highlighting some invalid syntax I had left in the file. With that corrected, the file now converts successfully to HTML.

Now I am looking at using various configuration options to get the desired result. The results so far are encouraging. It's when I see what other people and groups are doing that I get a little scared. Of course I need to realise that I need to do only the minimum with AsciiDoc to get what I want. If later our requirements change and we need to use a more complex configuration then OK, I'll do that. For the moment, though, the simple configuration I have is working.

AsciiDoc is part of a plan to make the production of the newsletter easier. Right now it's quite labour-intensive when more of the production steps could be automated (or at least semi-automated). I will report my progress here.

Sunday 30 January 2011

Amazing! Live Linux in your wallet

I recently bought a USB "key" (as they're commonly known here in Australia) which was essentially just the chip wrapped in plastic. It's so small that I'm almost certain to lose it at some point :). I also recently installed my first live Linux installation on a USB key. Live Linux installations are nothing new, and nor are small USB keys. Put the two together, though, and I think they're quite amazing. Imagine I need to run my favourite OS on a foreign PC. I don't need to carry a key in on my belt or hanging from a lanyard, I just need to open my wallet and there it is!

 
Store'n' Go Micro USB Drive Black 16GB

 
Although I have worked in IT for many years, I'm still often amazed at some of the things that technology makes possible.

 
Rock on!

Amazing! Live Linux in your wallet

I recently bought a USB "key" (as they're commonly known here in Australia) which was essentially just the chip wrapped in plastic. It's so small that I'm almost certain to lose it at some point :). I also recently installed my first live Linux installation on a USB key. Live Linux installations are nothing new, and nor are small USB keys. Put the two together, though, and I think they're quite amazing. Imagine I need to run my favourite OS on a foreign PC. I don't need to carry a key in on my belt or hanging from a lanyard, I just need to open my wallet and there it is!

 
Store'n' Go Micro USB Drive Black 16GB

 
Although I have worked in IT for many years, I'm still often amazed at some of the things that technology makes possible.

 
Rock on!

Wednesday 26 January 2011

I love Microsoft (mice) :) :(

Let me first say that I love FLOSS, both the idea and the products which are created in the spirit of openness. However in my personal experience I have found that I like Microsoft mice more than any other brand I have tried. Of course I haven't tried every brand in the world but over my many IT years I have tried quite a few. I recently bought my very first laptop and got from a friend a Microsoft wireless mouse.

 

I like the fact that Microsoft mice are usually: good looking, have quiet buttons and scroll wheels and make the Nano transceiver easily accessible. Compare this with a Logitech wireless mouse I use with a work laptop: the scroll wheel is quite noisy, the Nano transceiver is to be stored in the battery compartment, and it doesn't look nearly as nice as the Microsoft mouse.
I expect there are even better mice than the one I have but they soon become expensive. I don't think I'd ever pay much for a mouse, since I don't see the advantages. More money seems to bring you more buttons and on a mouse I most often use only the left and right buttons, together with the wheel (which of course also serves as a button). I don't need a mouse with 64 buttons. I am not a gamer, so incredible accuracy doesn't matter to me. As long as I can click on or select what I am aiming for, without the mouse pointer wandering, I'm happy.

In summary then, I apologise, but I like Microsoft mice. And as my psychiatrist asked me, "And how does that make you feel?", it makes me feel good to have a nice mouse, but bad that I'm using a Microsoft product. :)

Monday 3 January 2011

I have switched to Chromium as my primary web browser

A while ago I started using Opera as both my web browser and mail client. When I made the switch I was really pleased with the overall look of the browser and its functionality. It looked better than other web browsers, including Firefox and Chromium (at least I thought that at the time) and so I was happy to have an alternative. Opera might be free as in beer but it's definitely not free as in freedom. For reasons that I have never seen explained anywhere, even its bug tracker is not publicly available. You're welcome to report a bug but you have no way of knowing beforehand if anyone else has already reported it, nor if it anyone's working on it. After using it for a while I found that it had some strange quirks with several web sites I use regularly, including GMail. After finding out that I couldn't do anything to fix or avoid these, I simply began ignoring them.

 
Recently a work colleague suggested I use Chrome or Chromium instead. I hesitated because I had never been happy with Chromium's font handling because within the content window, all fonts looked slightly fuzzy. I had gone looking for help and finally found out that it was a known bug. I followed the bug for a while but there didn't seem to be much progress on it, nor were the developers particularly worried about it. It bothered me, though, and so I had been avoiding Chromium. I tried it again, though, and was surprised to find out that the bug had apparently disappeared. Fonts were now nice and crisp, at least as good as those in Firefox, for example.

 
I have been using Chromium now for about a week as my primary browser and am very happy (so far). I was frustrated that there was no option to force web pages to use your selected Serif and Sans Serif fonts. I did quite a lot of Googling and finally found out how to force this. It involved running Chromium with a command-line switch to enable user CSS, then editing the file produced by including this switch - Custom.css. It seemed a difficult way of doing something that's so simple in Firefox. I have also been surprised by how often I have tried an extension and found that the entire desktop environment has frozen solid, requiring me to turn the laptop off and on again. I believe I have resolved most of these issues by "downgrading" the visual effects I use in the GNOME desktop environment. I can't quite understand, though, why Chromium can cause such a "difficult" problem when the design states that every tab runs in a separate process. Anyway I have finally settled on just a few extensions that I find useful and don't freeze the desktop environment.

 
I'll keep on using Chromium but of course I reserve the right to switch to anything else when I want to. Now I need to find an email client, a function for which I had been using Opera. I don't really like Evolution, Thunderbird or Claws Mail but I will keep trying.