Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
proview
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Esteban Blanc
proview
Commits
acdcd0fd
Commit
acdcd0fd
authored
Jan 17, 2012
by
Claes Sjofors
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Flow, glow pango font free moved
parent
2819d5ce
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
xtt/lib/flow/gtk/flow_draw_gtk.cpp
xtt/lib/flow/gtk/flow_draw_gtk.cpp
+4
-4
xtt/lib/glow/gtk/glow_draw_gtk.cpp
xtt/lib/glow/gtk/glow_draw_gtk.cpp
+3
-3
No files found.
xtt/lib/flow/gtk/flow_draw_gtk.cpp
View file @
acdcd0fd
...
...
@@ -1241,7 +1241,6 @@ int FlowDrawGtk::text_pango( FlowCtx *ctx, int x, int y, char *text, int len,
PangoFontDescription
*
desc
=
pango_font_description_from_string
(
font_string
(
gc_type
,
size
));
pango_layout_set_font_description
(
layout
,
desc
);
pango_font_description_free
(
desc
);
int
w
,
h
;
pango_layout_get_size
(
layout
,
&
w
,
&
h
);
...
...
@@ -1256,6 +1255,7 @@ int FlowDrawGtk::text_pango( FlowCtx *ctx, int x, int y, char *text, int len,
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
0
);
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
0
);
g_object_unref
(
layout
);
pango_font_description_free
(
desc
);
g_object_unref
(
pctx
);
return
1
;
...
...
@@ -1287,7 +1287,6 @@ int FlowDrawGtk::text_inverse_pango( FlowCtx *ctx, int x, int y, char *text, int
PangoFontDescription
*
desc
=
pango_font_description_from_string
(
font_string
(
gc_type
,
size
));
pango_layout_set_font_description
(
layout
,
desc
);
pango_font_description_free
(
desc
);
int
w
,
h
;
pango_layout_get_size
(
layout
,
&
w
,
&
h
);
...
...
@@ -1297,6 +1296,7 @@ int FlowDrawGtk::text_inverse_pango( FlowCtx *ctx, int x, int y, char *text, int
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
0
);
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
0
);
g_object_unref
(
layout
);
pango_font_description_free
(
desc
);
g_object_unref
(
pctx
);
return
1
;
...
...
@@ -1328,7 +1328,6 @@ int FlowDrawGtk::text_erase_pango( FlowCtx *ctx, int x, int y, char *text, int l
PangoFontDescription
*
desc
=
pango_font_description_from_string
(
font_string
(
gc_type
,
size
));
pango_layout_set_font_description
(
layout
,
desc
);
pango_font_description_free
(
desc
);
int
w
,
h
;
pango_layout_get_size
(
layout
,
&
w
,
&
h
);
...
...
@@ -1341,6 +1340,7 @@ int FlowDrawGtk::text_erase_pango( FlowCtx *ctx, int x, int y, char *text, int l
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
0
);
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
0
);
g_object_unref
(
layout
);
pango_font_description_free
(
desc
);
g_object_unref
(
pctx
);
return
1
;
...
...
@@ -1729,7 +1729,6 @@ int FlowDrawGtk::get_text_extent_pango( FlowCtx *ctx, const char *text, int len,
PangoFontDescription
*
desc
=
pango_font_description_from_string
(
font_string
(
gc_type
,
size
));
pango_layout_set_font_description
(
layout
,
desc
);
pango_font_description_free
(
desc
);
int
w
,
h
;
pango_layout_get_size
(
layout
,
&
w
,
&
h
);
...
...
@@ -1740,6 +1739,7 @@ int FlowDrawGtk::get_text_extent_pango( FlowCtx *ctx, const char *text, int len,
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
0
);
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
0
);
g_object_unref
(
layout
);
pango_font_description_free
(
desc
);
g_object_unref
(
pctx
);
return
1
;
...
...
xtt/lib/glow/gtk/glow_draw_gtk.cpp
View file @
acdcd0fd
...
...
@@ -3547,7 +3547,6 @@ int GlowDrawGtk::text_pango( GlowWind *wind, int x, int y, char *text, int len,
PangoFontDescription
*
desc
=
pango_font_description_from_string
(
font_string
(
font_idx
,
font_type
,
size
));
pango_layout_set_font_description
(
layout
,
desc
);
pango_font_description_free
(
desc
);
int
width
,
height
;
pango_layout_get_size
(
layout
,
&
width
,
&
height
);
...
...
@@ -3577,6 +3576,7 @@ int GlowDrawGtk::text_pango( GlowWind *wind, int x, int y, char *text, int len,
pango_context_set_matrix
(
pc
,
0
);
}
g_object_unref
(
layout
);
pango_font_description_free
(
desc
);
}
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
0
);
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
0
);
...
...
@@ -3633,7 +3633,6 @@ int GlowDrawGtk::text_erase_pango( GlowWind *wind, int x, int y, char *text, int
PangoFontDescription
*
desc
=
pango_font_description_from_string
(
font_string
(
font_idx
,
font_type
,
size
));
pango_layout_set_font_description
(
layout
,
desc
);
pango_font_description_free
(
desc
);
int
width
,
height
;
pango_layout_get_size
(
layout
,
&
width
,
&
height
);
...
...
@@ -3668,6 +3667,7 @@ int GlowDrawGtk::text_erase_pango( GlowWind *wind, int x, int y, char *text, int
px
,
py
,
pw
,
ph
);
g_object_unref
(
layout
);
pango_font_description_free
(
desc
);
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
0
);
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
0
);
...
...
@@ -3713,7 +3713,6 @@ int GlowDrawGtk::get_text_extent_pango( const char *text, int len,
PangoFontDescription
*
desc
=
pango_font_description_from_string
(
font_string
(
font_idx
,
font_type
,
size
));
pango_layout_set_font_description
(
layout
,
desc
);
pango_font_description_free
(
desc
);
int
lwidth
,
lheight
;
pango_layout_get_size
(
layout
,
&
lwidth
,
&
lheight
);
...
...
@@ -3730,6 +3729,7 @@ int GlowDrawGtk::get_text_extent_pango( const char *text, int len,
*
descent
=
(
int
)(
FONT_DESCENT
*
lheight
/
PANGO_SCALE
);
g_object_unref
(
layout
);
pango_font_description_free
(
desc
);
gdk_pango_renderer_set_drawable
(
GDK_PANGO_RENDERER
(
pr
),
0
);
gdk_pango_renderer_set_gc
(
GDK_PANGO_RENDERER
(
pr
),
0
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment