From 68b736da7b6f1d0c92b690d3f5c45db3d957629d Mon Sep 17 00:00:00 2001 From: Cyrille Bagard Date: Fri, 31 Aug 2018 21:23:25 +0200 Subject: Loaded line segements without external image as surface origin. --- pixmaps/Makefile.am | 1 - pixmaps/nil.png | Bin 109 -> 0 bytes src/glibext/linesegment.c | 8 +------- 3 files changed, 1 insertion(+), 8 deletions(-) delete mode 100644 pixmaps/nil.png diff --git a/pixmaps/Makefile.am b/pixmaps/Makefile.am index eb3e6c2..03ab1d5 100644 --- a/pixmaps/Makefile.am +++ b/pixmaps/Makefile.am @@ -40,7 +40,6 @@ MISC = \ EXTRA_DIST = \ bookmark.png \ entrypoint.png \ - nil.png \ breakpoint_disabled.png \ breakpoint_normal.png \ chrysalide.xcf \ diff --git a/pixmaps/nil.png b/pixmaps/nil.png deleted file mode 100644 index ef6ecd7..0000000 Binary files a/pixmaps/nil.png and /dev/null differ diff --git a/src/glibext/linesegment.c b/src/glibext/linesegment.c index 02c6691..dc4a128 100644 --- a/src/glibext/linesegment.c +++ b/src/glibext/linesegment.c @@ -175,7 +175,6 @@ bool selection_list_has_segment_content(const segcnt_list *, const line_segment bool load_segment_rendering_parameters(void) { - gchar *filename; /* Accès à une image 1x1 */ cairo_font_slant_t s; /* Boucle de parcours #1 */ cairo_font_weight_t w; /* Boucle de parcours #2 */ cairo_t **cr; /* Contexte à créer */ @@ -185,15 +184,12 @@ bool load_segment_rendering_parameters(void) /* Contextes pour les mesures initiales */ - filename = find_pixmap_file("nil.png"); - if (filename == NULL) abort(); - for (s = CAIRO_FONT_SLANT_NORMAL; s < CAIRO_FONT_SLANT_COUNT; s++) for (w = CAIRO_FONT_WEIGHT_NORMAL; w < CAIRO_FONT_WEIGHT_COUNT; w++) { cr = &_seg_params.font_ctxts[CAIRO_FONT_INDEX(s, w)]; - surface = cairo_image_surface_create_from_png(filename); + surface = cairo_image_surface_create(CAIRO_FORMAT_ARGB32, 1, 1); *cr = cairo_create(surface); cairo_surface_destroy(surface); @@ -205,8 +201,6 @@ bool load_segment_rendering_parameters(void) } - g_free(filename); - /* Fond d'impression */ _seg_params.selection_bg.has_color = true; -- cgit v0.11.2-87-g4458