SEARCH

Enter your search query in the box above ^, or use the forum search tool.

You are not logged in.

#1 2010-01-15 01:37:36

Mguel
New Member
Registered: 2010-01-01
Posts: 7

gsimplecal: Lightweight calendar to display when clicking the clock

Hi,

I was looking on the forums, on the repositories and on the web for a lightweight calendar to display when clicking on tint2 clock. The most near alternative was orage, but it required several packages (including xfce4-panel) totaling 14.1 Mb! which was way too much for simply displaying a calendar. Although I have conky displaying a calendar of the current month I wanted a calendar which I could see other months (just like orage but without all the dependencies it has).

Today I found:
http://code.google.com/p/gsimplecal/

To install it (not sure if it's the best way) I downloaded all the files from:
http://code.google.com/p/gsimplecal/source/browse/
to
/opt/gsimplecal
And added permission to execute gsimplecal file.

It requires to install only one additional package: libunique-1.0-0. So you can install it with synaptic or:

sudo apt-get install libunique-1.0-0

Added on tint2rc:

clock_lclick_command = /opt/gsimplecal/gsimplecal

And that's it...

Note: The calendar has no close button, but it closes running the app again (clicking on the clock for a second time), which makes its integration great imo.

I leave you a screenshot of my desktop with the calendar:
100114crunchbangcal.th.jpg

Cheers,
Mguel

Offline

Help fund CrunchBang, donate to the project!

#2 2010-01-15 15:11:26

atomicbricks
#! CrunchBanger
From: Cambridge, MA, USA
Registered: 2010-01-12
Posts: 100

Re: gsimplecal: Lightweight calendar to display when clicking the clock

Thanks, I was looking for something like that.

Also, would you mind posting your conky configuration file over at this thread?
http://crunchbanglinux.org/forums/topic … ky-config/
You've got some cool stuff going on there and I want to see how it was done.

Offline

#3 2010-01-16 05:45:38

slipshot
#! CrunchBanger
Registered: 2009-05-13
Posts: 171

Re: gsimplecal: Lightweight calendar to display when clicking the clock

i cant get this to work every time i try to execute the gsimplecal file i get bash: ./gsimplecal: cannot execute binary file
and it wont let me install it with make because i get a long list of errors
i installed libunique but still nothing any ideas?

Offline

#4 2010-01-17 17:59:55

Chetamonye
#! Member
From: California
Registered: 2009-07-23
Posts: 65

Re: gsimplecal: Lightweight calendar to display when clicking the clock

While reading these posts I decided to try an alternative.

I can't remember if Crunch comes with Zenity installed or if I did it myself.  If not, just use apt-get.

Edit the tint2rc file.  In the Clock section, add the following.

clock_lclick_command = zenity --calendar

Save the file. 

The next time you log in and click on the clock, you will get a calendar.  It will stay on screen until you click on Cancel or Ok.

That's it.

Chet

Offline

#5 2010-01-17 18:43:47

benj1
Wiki Wizard
From: Yorkshire, England
Registered: 2009-09-05
Posts: 1,084

Re: gsimplecal: Lightweight calendar to display when clicking the clock

i just use a dzen2 script

# based on (c) 2007, by Robert Manea
# http://dzen.geekmode.org/dwiki/doku.php?id=dzen:calendar
# modified by urukrama
# and again by me
# 

if [ -f /tmp/panel-calendar.lock ] ; then
  # the lock file already exists, process is still running
  
  #kill panel-calendar process
  kill `cat /tmp/panel-calendar.lock`
  
  #kill correct dzen2 process (better to be more specific than less)
  ps ux | awk '/dzen2 -x 828 -y 725 -w 190 -l 9 -sa c -fn -\*-fixed-\*-\*-\*-\*-12-\*-\*-\*-\*-\*-\*-\* -e onstart uncollapse key_Escape ungrabkeys exit/ && !/awk/ {print $2}'| xargs kill 
  
  rm /tmp/panel-calendar.lock
  exit 0
fi

#generate log files
echo $$ > /tmp/panel-calendar.lock

TODAY=$(expr `date +'%d'` + 0)
BG='#222222'
#FG='#2eca2c'
FG='#28AA28'
(
echo; echo "^fg(#28AA28)"`date +'%A %d'`;

# current month, hilight header and today
cal -m  | sed -r -e "1,2 s/.*/^fg($FG)&^fg()/" \
         -e "s/(^| )($TODAY)($| )/\1^bg($FG)^fg(#6C6C6C)\2^fg()^bg()\3/"

#display for 8 seconds
sleep 8

#remove lock when we have finished
rm /tmp/panel-calendar.lock

) | dzen2 -x 828 -y 725 -w 190 -l 9 -sa c -fn '-*-fixed-*-*-*-*-12-*-*-*-*-*-*-*' -e 'onstart=uncollapse;key_Escape=ungrabkeys,exit'

nicked from the dzen2 site originally i think, closes when you click on the clock or after 8 seconds.


- - - - - - - - Wiki Pages - - - - - - -
#! install guide           *autostart programs, modify the menu & keybindings
configuring Conky       *installing scripts

Offline

#6 2010-01-17 23:33:26

slapfish
#! Die Hard
From: Athens, Greece
Registered: 2009-10-22
Posts: 601

Re: gsimplecal: Lightweight calendar to display when clicking the clock

clock_lclick_command = osmo -c

Offline

#7 2010-01-19 03:53:43

Mguel
New Member
Registered: 2010-01-01
Posts: 7

Re: gsimplecal: Lightweight calendar to display when clicking the clock

samoflange wrote:

Also, would you mind posting your conky configuration file over at this thread?
http://crunchbanglinux.org/forums/topic … ky-config/

OK...

Chetamonye wrote:

clock_lclick_command = zenity --calendar

That would ended all my search but didn't know about that until now tongue.
Now I've installed this gsimplecal... I prefer it since I believe it integrates better (it appears on the corner next to the clock, it closes by clicking it a second time, it's smaller with no OK/Cancel buttons)


slipshot wrote:

i cant get this to work every time i try to execute the gsimplecal file i get bash: ./gsimplecal: cannot execute binary file
and it wont let me install it with make because i get a long list of errors
i installed libunique but still nothing any ideas?

I didn't have problems installing it on my desktop nor my dell xps m1210 notebook. But on my AAO I got the same error you are mentioning... don't know why and haven't have time to try to guess or search for an explication/solution.

Sorry

Offline

#8 2010-01-19 15:55:59

paulsenior
#! CrunchBanger
From: Muenster, Germany
Registered: 2009-02-12
Posts: 100

Re: gsimplecal: Lightweight calendar to display when clicking the clock

Hey there,

clock_lclick_command = zenity --calendar

opens only one time the calendar, if i close it and click again on the clock nothing happens.... any ideas?


From Germany --> Bad English smile

Offline

#9 2010-01-19 19:47:55

Digit
#! Die Hard
From: the internet
Registered: 2009-05-26
Posts: 972
Website

Re: gsimplecal: Lightweight calendar to display when clicking the clock

sweeet.

thnx guys.

i stuck zenity (already installed) on my right click (prefering xclock, for left), and it works a charm.  paulsenior, even after closing it.

doesnt really do anything besides show a calendar... cant schedule stuff or anything else interactive n useful, but its a start.  big_smile
...i have plans for making a mayan tzolkin calendar thingy, when i can find the time to dedicate to it again.  smile


in honour of Aaron H. Swartz,
make liberating JSTOR (and similar)'s database(s) of knowledge from behind paywalls your #1 priority,
and keep making the world a better place.
live up to what he lived for.

Offline

#10 2010-01-20 05:55:07

Chetamonye
#! Member
From: California
Registered: 2009-07-23
Posts: 65

Re: gsimplecal: Lightweight calendar to display when clicking the clock

paulsenior wrote:

Hey there,

clock_lclick_command = zenity --calendar

opens only one time the calendar, if i close it and click again on the clock nothing happens.... any ideas?

Sorry.  I couldn't really say. 

Can you post your tint2rc?  Maybe there is something in there causing a conflict.

Chet

Offline

#11 2010-01-20 12:35:28

paulsenior
#! CrunchBanger
From: Muenster, Germany
Registered: 2009-02-12
Posts: 100

Re: gsimplecal: Lightweight calendar to display when clicking the clock

Thanks for the help wink

Here it is, nothing special....
http://pastebin.com/f563a9f3f

Last edited by paulsenior (2010-01-20 12:36:38)


From Germany --> Bad English smile

Offline

#12 2010-01-31 18:38:45

dove
#! CrunchBanger
Registered: 2009-07-28
Posts: 150

Re: gsimplecal: Lightweight calendar to display when clicking the clock

would anyone be so kind as to tell me where on this link        http://code.google.com/p/gsimplecal/source/browse/           that will allow me to download     gsimplecal ??

Offline

#13 2010-01-31 20:01:02

anonymous
The Mystery Member
From: Arch Linux Forums
Registered: 2008-11-29
Posts: 8,901

Re: gsimplecal: Lightweight calendar to display when clicking the clock

I have been unable to save all the files. I'd try Chetamonye's trick of using the zenity calendar.


Note: ** Please read before posting **

BTW if you wish to contact me, send me an e-mail instead of a PM.

Offline

#14 2010-01-31 21:23:56

pvsage
Internal Affairs
From: North Carolina
Registered: 2009-10-18
Posts: 9,009

Re: gsimplecal: Lightweight calendar to display when clicking the clock

I like the osmo calendar - didn't even realize that was installed in #! - but I agree Zenity is a very handy GTK tool.


while ( ! ( succeed = try() ) );
We've earned a reputation as a nice, friendly community; please help us keep it that way.

Offline

#15 2010-02-01 00:50:08

dove
#! CrunchBanger
Registered: 2009-07-28
Posts: 150

Re: gsimplecal: Lightweight calendar to display when clicking the clock

anonymous wrote:

I have been unable to save all the files. I'd try Chetamonye's trick of using the zenity calendar.

  yes this worked great-thanx

Offline

#16 2010-02-01 01:58:15

compost
New Member
Registered: 2010-02-01
Posts: 3

Re: gsimplecal: Lightweight calendar to display when clicking the clock

If you are having trouble downloading the files try this link:
http://gsimplecal.googlecode.com/hg/

I can't seem to get the binary to execute.

I did get it working though. I compiled from source, but I had to install libunique-1.0-0, libunique-dev (which is quite large), pkg-config, and g++. Afterwards I ran:

sudo apt-get remove libunique-dev; sudo apt-get autoremove

I've been using Linux for a couple of years now but I'm no programmer so this took quite a bit of googling. It was worth it though, looks nice!

Offline

#17 2010-02-13 06:24:21

Chetamonye
#! Member
From: California
Registered: 2009-07-23
Posts: 65

Re: gsimplecal: Lightweight calendar to display when clicking the clock

Digit wrote:

sweeet.

doesnt really do anything besides show a calendar... cant schedule stuff or anything else interactive n useful, but its a start.  big_smile
...i have plans for making a mayan tzolkin calendar thingy, when i can find the time to dedicate to it again.  smile

Hey Digit.  I was thinking about your comment regarding not being able to schedule anything.  It got me thinking and I came up with a new twist.

In the tintrc2 file change

clock_lclick_command = zenity --calendar

to

clock_lclick_command = /home/your name/call_calendar.sh  Don't forget to edit the directory name.

create a file called call_calendar.sh and paste the following:


#!/bin/bash
# call_calendar.sh
# 02/12/10 - Chetamonye
# Pop up Calendar and/or run
# scheduling program
# run a program or use a web calendar
# add or remove '#' to just choose one.

CAL_GET=`zenity --calendar --text "Cancel to close. Ok to schedule an appt" --title "My Calendar"`

case $? in
    0)
        #sunbird ;; put program here and remove line below
        google-chrome http://www.google.com/calendar/render ;;
    1)
        exit ;;
    255)
        echo "Box closed.";;
esac

The line with sunbird will run the sunbird calendar program if you remove the hash mark.  You can use a different program like evolution, or whatever.  If you prefer a web based calendar, modify the line with google-chrome one it.

Make sure to chmod +x to make it executable.

When you click on the date in the tint2 bar, you get the same calendar.  If you click cancel, it goes away.  If you click OK, you will get your chosen calendar program.

Simple.  As always feel free to expand and improve the script.


Chet

Offline

#18 2010-03-07 07:20:01

Barthalion
New Member
Registered: 2010-03-07
Posts: 1

Re: gsimplecal: Lightweight calendar to display when clicking the clock

When I try to run gsimplecal from tint2 I get:

(gsimplecal:17054): Unique-DBus-WARNING **: Unable to open a connection to the session bus: /usr/bin/dbus-launch terminated abnormally without any error message

(gsimplecal:17054): Unique-DBus-WARNING **: Unable to connect to the running instance, aborting.

Manually run works.

Offline

Board footer

Powered by FluxBB

Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.

Debian Logo