Matthias Clasen
5b0ea70d1c
textattributes: Small docs fix
2021-04-04 22:27:53 -04:00
Matthias Clasen
4fce3ceffc
Cosmetics
...
Pack the GtkTextAttributes struct better.
2021-03-18 22:53:37 -04:00
Emmanuele Bassi
ea5e186bb8
Hide GtkTextAttributes functions
...
The type is private, so making functions operating on it public is
pointless.
2020-12-15 16:20:21 +00:00
Matthias Clasen
929a56e53c
Clean up lots of GTK+ -> GTK
...
Replace most remaining uses of GTK+ in the docs and
user-visible strings by GTK. Also remove some leftover
"Was added in 3.x" sentences from the docs.
2020-09-12 12:01:04 -04:00
Benjamin Otte
3078b180fe
Replace "gdouble" with "double"
2020-07-25 00:47:36 +02:00
Benjamin Otte
d375dce9f5
Replace "gchar" with "char"
2020-07-25 00:47:36 +02:00
Benjamin Otte
d7266b25ba
Replace "gint" with "int"
2020-07-25 00:47:36 +02:00
Matthias Clasen
a8c6ae6085
texttag: Support overline and hyphenation control
...
Add support for recently added Pango attributes
for overlines and hyphenation control. The new
properties of GtkTextTag are
overline, overline-rgba, allow-breaks, show-spaces
and insert-hyphens.
2020-03-20 23:58:23 -04:00
Matthias Clasen
2c26f0cae4
Complete the privatization of GtkTextAttributes
...
This was not quite complete, as gtktextattributes.h was still
being included in public headers.
https://bugzilla.gnome.org/show_bug.cgi?id=773903
2016-11-04 12:05:52 -04:00
Matthias Clasen
6e178aede2
Use GdkRGBA for text attributes
...
Now that GtkTextAttributes is private, we can clean this struct
up a bit. The first step is to switch from GdkColor to GdkRGBA,
and adapt all users.
2016-11-01 13:58:10 -04:00
Timm Bäder
a5867ffe71
Remove some more GdkColor properties
2016-10-20 20:12:08 +02:00
Matthias Clasen
c6838fbff0
GtkTextView: Support font features
...
Add a ::font-features attribute to GtkTextTag, and support
font features when inserting Pango markup into a text buffer.
2015-07-29 21:42:58 -04:00
Christian Hergert
28063ee2e4
textview: add support for underline and strikethrough colors
...
This commit adds the GtkTextTag:underline-rgba and :strikethrough-rgba
properties and the necessary plumbing to apply these colors in GtkTextLayout.
With this change, you can alter the color of underlines including those
of type PANGO_UNDERLINE_ERROR.
You might want to alter the underline color to differentiate between
spelling and grammer mistakes. In code editors, it is convenient to
differentiate between errors and warnings.
Note that the GtkTextAppearance struct is public ABI and has no spare
room for new fields, so we are resorting to some tricky packing to store
the colors in the unused pixel field of the fg_color and bg_color structs.
This packing is accomplished by the macros in gtktextattributesprivate.h.
Signed-off-by: Christian Hergert <christian@hergert.me>
https://bugzilla.gnome.org/show_bug.cgi?id=402168
2015-03-17 23:24:13 -04:00
Matthias Clasen
e1716611bd
Update docs
...
Document new fields in GtkTextAttributes, remove redundant comments.
2014-12-05 20:10:11 -05:00
Matthias Clasen
d184088cae
GtkTextView: Add fallback and letter-spacing support
...
Add support for the Pango attributes controlling font fallback
and letter spacing to GtkTextTag.
https://bugzilla.gnome.org/show_bug.cgi?id=740954
2014-12-04 00:09:44 -05:00
William Jon McCann
7a208fbbf3
docs: use proper apostrophe
...
https://wiki.gnome.org/Design/OS/Typography
2014-02-07 13:06:10 -05:00
William Jon McCann
ed284234c9
docs: add docs for GtkTextAppearance
2014-01-21 13:33:47 -05:00
William Jon McCann
1ec4b0cff2
docs: add field descriptions for GtkTextAttributes
2014-01-21 13:33:19 -05:00
Colin Walters
3c6c90086f
gtktextattributes: Only use transparent union for g-ir-scanner
...
https://bugzilla.gnome.org/show_bug.cgi?id=711158
2013-11-13 12:59:57 -05:00
Colin Walters
c9892df362
gtktextattributes: Use an anonymous union instead of arch-testing #ifdef
...
This avoids having Gtk-3.0.gir differ on 32 vs 64 bit, which causes
issues for "multilib" in Fedora/OpenSUSE type systems.
See https://bugzilla.gnome.org/show_bug.cgi?id=711153 for more
information.
https://bugzilla.gnome.org/show_bug.cgi?id=711158
2013-11-03 11:15:43 -05:00
Matthias Clasen
20c8c8b91c
Add annotations to gtk headers
...
Add annotations to all exported functions in GTK+ headers.
2013-05-05 15:38:47 -04:00
Sébastien Wilmet
d599985a41
gtktextattributes: move comment above relevant struct
...
https://bugzilla.gnome.org/show_bug.cgi?id=697048
2013-04-01 21:12:49 +02:00
Sébastien Wilmet
6f990fa7e4
gtktextattributes: explain what is "pg_bg"
...
I didn't know what "pg" stands for.
https://bugzilla.gnome.org/show_bug.cgi?id=697048
2013-04-01 21:12:49 +02:00
Matthias Clasen
5adecf183b
Move single-include guards inside include guards
...
gcc has optimizations for include guards that only work
if they are outermost in the the header.
https://bugzilla.gnome.org/show_bug.cgi?id=689810
2012-12-28 09:57:56 -05:00
Antoine Jacoutot
f44b8465f1
__SIZEOF_INT__ and __SIZEOF_POINTER__ may not be defined.
...
Protect __SIZEOF_INT__ and __SIZEOF_POINTER__ with an ifdef to prevent
warnings about them not being defined when including gtktextattributes.h.
https://bugzilla.gnome.org/show_bug.cgi?id=660619
2011-10-03 09:11:50 +02:00
Tristan Van Berkom
d399a4acab
Added GdkRGBA properties to GtkTextTag.
...
This now allows text view to render text with alpha values in
the text foreground and backgrounds, the work is almost complete,
currently the error-underline-color is still a GdkColor style property
and since we use only GdkRGBA for rendering it needs to be converted
and applied, probably a new rgba version of the style property should
also be introduced.
This commit adds tests/testtextview that must be run from the tests/
directory to show translucent text in action.
2011-05-06 17:05:10 -04:00
Matthias Clasen
6cf78a12c1
Move GtkTextTag docs inline
2011-01-14 17:49:48 -05:00
Benjamin Otte
7fae37ecd5
textview: Move GtkTextAttributes to its own header
2011-01-11 16:46:59 +01:00