

Go to the source code of this file.
Data Structures | |
| struct | binary_stream |
| binary_stream - struct definition to read binary data into cairo surface More... | |
Macros | |
| #define | XPNGLOADER_H_ |
| #define | EXTLD(NAME) |
| #define | LDVAR(NAME) _binary_ ## NAME ## _start |
| #define | LDLEN(NAME) ((_binary_ ## NAME ## _end) - (_binary_ ## NAME ## _start)) |
Functions | |
| cairo_surface_t * | cairo_image_surface_create_from_stream (const unsigned char *name) |
| cairo_image_surface_create_from_stream - read binary data into cairo surface from stream More... | |
| void | widget_get_png (Widget_t *w, const unsigned char *name) |
| widget_get_png - read png into Widget_t xlib surface More... | |
| void | widget_get_scaled_png (Widget_t *w, const unsigned char *name) |
| widget_get_scaled_png - read scaled png into Widget_t xlib surface More... | |
| void | widget_get_surface_ptr (Widget_t *w, Widget_t *wid) |
| widget_get_surface_ptr - set pointer to a 2. Widget_t xlib surface More... | |
| cairo_surface_t * | surface_get_png (Widget_t *w, cairo_surface_t *sf, const unsigned char *name) |
| surface_get_png - read png into Widget_t xlib surface More... | |
| void | widget_set_icon_from_surface (Widget_t *w, Pixmap *icon_, cairo_surface_t *image) |
| widget_set_icon_from_surface - set icon image from cairo surface for Widget_t those icon will be used in the Window decoration and the toolbar (depending on the Widnow manager) More... | |
| void | widget_set_icon_from_png (Widget_t *w, Pixmap *icon_, const unsigned char *name) |
| widget_set_icon_from_png - set icon image from png binary to Widget_t those icon will be used in the Window decoration and the toolbar (depending on the Widnow manager) More... | |
| #define EXTLD | ( | NAME | ) |
define some MACROS to read png data from binary stream png's been converted to object files with ld -r -b binary name.png -o name.o
Definition at line 68 of file xpngloader.h.
| #define LDLEN | ( | NAME | ) | ((_binary_ ## NAME ## _end) - (_binary_ ## NAME ## _start)) |
Definition at line 73 of file xpngloader.h.
| #define LDVAR | ( | NAME | ) | _binary_ ## NAME ## _start |
Definition at line 71 of file xpngloader.h.
| #define XPNGLOADER_H_ |
Definition at line 24 of file xpngloader.h.
| cairo_surface_t* cairo_image_surface_create_from_stream | ( | const unsigned char * | name | ) |
cairo_image_surface_create_from_stream - read binary data into cairo surface from stream
| *name | - pointer to the binary image data LDVAR(name) |
Definition at line 34 of file xpngloader.c.
References binary_stream::data, png_stream_reader(), and binary_stream::position.
| cairo_surface_t* surface_get_png | ( | Widget_t * | w, |
| cairo_surface_t * | sf, | ||
| const unsigned char * | name | ||
| ) |
surface_get_png - read png into Widget_t xlib surface
| *w | - pointer to the Widget_t which should use the png |
| *sf | - pointer to the cairo_surface_t which should hold the png |
| *name | - pointer to the binary image data LDVAR(name) |
Definition at line 83 of file xpngloader.c.
References cairo_image_surface_create_from_stream(), and Widget_t::surface.
| void widget_get_png | ( | Widget_t * | w, |
| const unsigned char * | name | ||
| ) |
widget_get_png - read png into Widget_t xlib surface
| *w | - pointer to the Widget_t which should use the png |
| *name | - pointer to the binary image data LDVAR(name) |
Definition at line 41 of file xpngloader.c.
References cairo_image_surface_create_from_stream(), Widget_t::image, and Widget_t::surface.
| void widget_get_scaled_png | ( | Widget_t * | w, |
| const unsigned char * | name | ||
| ) |
widget_get_scaled_png - read scaled png into Widget_t xlib surface
| *w | - pointer to the Widget_t which should use the png |
| *name | - pointer to the binary image data LDVAR(name) |
Definition at line 57 of file xpngloader.c.
References cairo_image_surface_create_from_stream(), Widget_t::image, Resize_t::init_height, Resize_t::init_width, Widget_t::scale, and Widget_t::surface.
widget_get_surface_ptr - set pointer to a 2. Widget_t xlib surface
| *w | - pointer to the Widget_t which should use the surface |
| *wid | - pointer to the Widget_t which hold the surface |
Definition at line 78 of file xpngloader.c.
References Widget_t::flags, Widget_t::image, and REUSE_IMAGE.
| void widget_set_icon_from_png | ( | Widget_t * | w, |
| Pixmap * | icon_, | ||
| const unsigned char * | name | ||
| ) |
widget_set_icon_from_png - set icon image from png binary to Widget_t those icon will be used in the Window decoration and the toolbar (depending on the Widnow manager)
| *w | - pointer to the Widget_t which should use the icon |
| *name | - pointer to the binary image data LDVAR(name) |
Definition at line 124 of file xpngloader.c.
References Widget_t::app, Colors::bg, cairo_image_surface_create_from_stream(), Xputty::dpy, get_color_scheme(), PRELIGHT_, and Widget_t::widget.
| void widget_set_icon_from_surface | ( | Widget_t * | w, |
| Pixmap * | icon_, | ||
| cairo_surface_t * | image | ||
| ) |
widget_set_icon_from_surface - set icon image from cairo surface for Widget_t those icon will be used in the Window decoration and the toolbar (depending on the Widnow manager)
| *w | - pointer to the Widget_t which should use the icon |
| *image | - pointer to the cairo_surface_t to use for the icon |
Definition at line 98 of file xpngloader.c.
References Widget_t::app, Colors::bg, Xputty::dpy, get_color_scheme(), PRELIGHT_, and Widget_t::widget.