Open main menu
Home
Random
Log in
Settings
About Sugar Labs
Disclaimers
Sugar Labs
Search
Changes
← Older edit
Newer edit →
Features/GTK3/Porting
(view source)
Revision as of 13:41, 11 November 2011
265 bytes added
,
13:41, 11 November 2011
→Going from Cairo in GTK-2 to Cairo in GTK-3
Line 270:
Line 270:
Not much changes, but...
Not much changes, but...
+
+
The Cairo/Pango interaction is a little different:
+
<pre>
+
cr = ...
+
pl = PangoCairo.create_layout(cr)
+
pl.set_font_description(fd)
+
pl.set_text('Hello World', -1)
+
cr.set_source_rgb(1, 0, 0)
+
PangoCairo.update_layout(cr, pl)
+
PangoCairo.show_layout(cr, pl)
+
</pre>
===Taking a screenshot and making a thumbnail===
===Taking a screenshot and making a thumbnail===
Walter
Bureaucrats
,
Administrators
10,579
edits