tags:

views:

69

answers:

3

I am using sticky notes in ubuntu . And was wondering if it would be possible to read the text written in sticky notes using any scripting language .

+1  A: 

I am not sure whether you can do it using the sticky notes, but assuming if you use Tomboy, you can do it.

You need tomboycli, a Python script which provides access to Tomboy through d-bus.

The project is hosted on Google Code here. Maybe you can study this to make your own implementation if you are interested.

sukhbir
A: 

The tomboy notes are saved as xml files so you could write a xml parser.

vurte
+2  A: 

If you meant the "Sticky Notes" applet you can add to your panel then yes you can read that notes too.

The XML file containing all notes typically is located at ~/.gnome2/stickynotes_applet.

You just have to parse the information you need out of it. The structure should look like this.

<?xml version="1.0"?>
<stickynotes version="2.30.0">
    <note title="10/31/2010" x="658" y="176" w="477" h="418">Some text</note>
</stickynotes>

Where xstands for the notes position on the x-axis, yfor its position on the y-axis, w stands for the width and h stands for the height.

It should be pretty simple to build a parser for it using Perl for example.

Octavian Damiean