all repos — tint2 @ 5b4d782ca2b9d91e4ca16b2cd4f825c2191c42a4

fork of the tint2 desktop panel for my custom setup - only minimized windows across all desktops for the taskbar

src/clock/clock.h (raw)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/**************************************************************************
* Copyright (C) 2008 thierry lorthiois (lorthiois@bbsoft.fr)
*
* Clock with fonctionnal data (timeval, precision) and drawing data (area, font, ...).
* Each panel use his own drawing data.
* 
**************************************************************************/

#ifndef CLOCK_H
#define CLOCK_H

#include <sys/time.h>
#include "common.h"
#include "area.h"


typedef struct Clock {
   // always start with area
   Area area;

   config_color font;
   PangoFontDescription *time1_font_desc;
   PangoFontDescription *time2_font_desc;
   int time1_posy;
   int time2_posy;
} Clock;

extern char *time1_format;
extern char *time2_format;
extern struct timeval time_clock;
extern int  time_precision;


// initialize clock : y position, precision, ...
void init_clock(Clock *clock, int panel_height);

void draw_foreground_clock (void *obj, cairo_t *c, int active);


#endif