From b4a4db44ddb51d919d2b738258c1ebd5a7f29d4b Mon Sep 17 00:00:00 2001 From: Dan Winship Date: Sun, 24 Apr 2005 22:35:43 +0000 Subject: [PATCH] * pango/Attribute.cs: Base class for Pango attributes, a la Gdk.Event * pango/pango-symbols.xml: explain how to marshal PangoAttribute. * pango/AttrBackground.cs: * pango/AttrFallback.cs: * pango/AttrFamily.cs: * pango/AttrFontDesc.cs: * pango/AttrForeground.cs: * pango/AttrLanguage.cs: * pango/AttrLetterSpacing.cs: * pango/AttrRise.cs: * pango/AttrScale.cs: * pango/AttrShape.cs: * pango/AttrSize.cs: * pango/AttrStretch.cs: * pango/AttrStrikethrough.cs: * pango/AttrStrikethroughColor.cs: * pango/AttrStyle.cs: * pango/AttrUnderline.cs: * pango/AttrUnderlineColor.cs: * pango/AttrVariant.cs: * pango/AttrWeight.cs: subclasses of Attribute, with proper constructors. These don't actually correspond one-to-one with the underlying types, but they're nicer this way. * pango/Pango.metadata: Hide Attribute and its subclasses from the generator. Also hide "Attr" (which previously contained non-working badly-named static methods to create Attributes) and AttrClass (which is not really useful outside of pango itself). * pango/AttrIterator.custom: use Pango.Attribute.GetAttribute. * pango/glue/attribute.c: glue for Attribute and its subclasses [Fixes #52575 and its semi-dup #46552] svn path=/trunk/gtk-sharp/; revision=43520 --- ChangeLog | 41 ++++ doc/ChangeLog | 4 + doc/en/Pango/Attr.xml | 307 ------------------------ doc/en/Pango/AttrBackground.xml | 74 ++++++ doc/en/Pango/AttrClass.xml | 64 ----- doc/en/Pango/AttrColor.xml | 77 ------ doc/en/Pango/AttrFallback.xml | 67 ++++++ doc/en/Pango/AttrFamily.xml | 56 +++++ doc/en/Pango/AttrFloat.xml | 77 ------ doc/en/Pango/AttrFontDesc.xml | 77 ++---- doc/en/Pango/AttrForeground.xml | 74 ++++++ doc/en/Pango/AttrInt.xml | 77 ------ doc/en/Pango/AttrLanguage.xml | 69 +----- doc/en/Pango/AttrLetterSpacing.xml | 56 +++++ doc/en/Pango/AttrRise.xml | 56 +++++ doc/en/Pango/AttrScale.xml | 56 +++++ doc/en/Pango/AttrShape.xml | 127 ++-------- doc/en/Pango/AttrSize.xml | 110 ++++----- doc/en/Pango/AttrStretch.xml | 56 +++++ doc/en/Pango/AttrStrikethrough.xml | 56 +++++ doc/en/Pango/AttrStrikethroughColor.xml | 74 ++++++ doc/en/Pango/AttrString.xml | 77 ------ doc/en/Pango/AttrStyle.xml | 56 +++++ doc/en/Pango/AttrUnderline.xml | 56 +++++ doc/en/Pango/AttrUnderlineColor.xml | 74 ++++++ doc/en/Pango/AttrVariant.xml | 56 +++++ doc/en/Pango/AttrWeight.xml | 56 +++++ doc/en/Pango/Attribute.xml | 141 ++++++----- pango/AttrBackground.cs | 44 ++++ pango/AttrFallback.cs | 42 ++++ pango/AttrFamily.cs | 51 ++++ pango/AttrFontDesc.cs | 43 ++++ pango/AttrForeground.cs | 44 ++++ pango/AttrIterator.custom | 8 +- pango/AttrLanguage.cs | 43 ++++ pango/AttrLetterSpacing.cs | 42 ++++ pango/AttrRise.cs | 42 ++++ pango/AttrScale.cs | 42 ++++ pango/AttrShape.cs | 51 ++++ pango/AttrSize.cs | 56 +++++ pango/AttrStretch.cs | 42 ++++ pango/AttrStrikethrough.cs | 42 ++++ pango/AttrStrikethroughColor.cs | 44 ++++ pango/AttrStyle.cs | 42 ++++ pango/AttrUnderline.cs | 42 ++++ pango/AttrUnderlineColor.cs | 44 ++++ pango/AttrVariant.cs | 42 ++++ pango/AttrWeight.cs | 42 ++++ pango/Attribute.cs | 161 +++++++++++++ pango/Makefile.am | 24 +- pango/Pango.metadata | 11 + pango/glue/Makefile.am | 1 + pango/glue/attribute.c | 130 ++++++++++ pango/glue/makefile.win32 | 1 + pango/pango-symbols.xml | 5 + 55 files changed, 2323 insertions(+), 1029 deletions(-) delete mode 100644 doc/en/Pango/Attr.xml create mode 100644 doc/en/Pango/AttrBackground.xml delete mode 100644 doc/en/Pango/AttrClass.xml delete mode 100644 doc/en/Pango/AttrColor.xml create mode 100644 doc/en/Pango/AttrFallback.xml create mode 100644 doc/en/Pango/AttrFamily.xml delete mode 100644 doc/en/Pango/AttrFloat.xml create mode 100644 doc/en/Pango/AttrForeground.xml delete mode 100644 doc/en/Pango/AttrInt.xml create mode 100644 doc/en/Pango/AttrLetterSpacing.xml create mode 100644 doc/en/Pango/AttrRise.xml create mode 100644 doc/en/Pango/AttrScale.xml create mode 100644 doc/en/Pango/AttrStretch.xml create mode 100644 doc/en/Pango/AttrStrikethrough.xml create mode 100644 doc/en/Pango/AttrStrikethroughColor.xml delete mode 100644 doc/en/Pango/AttrString.xml create mode 100644 doc/en/Pango/AttrStyle.xml create mode 100644 doc/en/Pango/AttrUnderline.xml create mode 100644 doc/en/Pango/AttrUnderlineColor.xml create mode 100644 doc/en/Pango/AttrVariant.xml create mode 100644 doc/en/Pango/AttrWeight.xml create mode 100644 pango/AttrBackground.cs create mode 100644 pango/AttrFallback.cs create mode 100644 pango/AttrFamily.cs create mode 100644 pango/AttrFontDesc.cs create mode 100644 pango/AttrForeground.cs create mode 100644 pango/AttrLanguage.cs create mode 100644 pango/AttrLetterSpacing.cs create mode 100644 pango/AttrRise.cs create mode 100644 pango/AttrScale.cs create mode 100644 pango/AttrShape.cs create mode 100644 pango/AttrSize.cs create mode 100644 pango/AttrStretch.cs create mode 100644 pango/AttrStrikethrough.cs create mode 100644 pango/AttrStrikethroughColor.cs create mode 100644 pango/AttrStyle.cs create mode 100644 pango/AttrUnderline.cs create mode 100644 pango/AttrUnderlineColor.cs create mode 100644 pango/AttrVariant.cs create mode 100644 pango/AttrWeight.cs create mode 100644 pango/Attribute.cs create mode 100644 pango/glue/attribute.c create mode 100644 pango/pango-symbols.xml diff --git a/ChangeLog b/ChangeLog index 1634b6d8d..4a8e225e5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,44 @@ +2005-04-24 Dan Winship + + * pango/Attribute.cs: Base class for Pango attributes, a la + Gdk.Event + + * pango/pango-symbols.xml: explain how to marshal PangoAttribute. + + * pango/AttrBackground.cs: + * pango/AttrFallback.cs: + * pango/AttrFamily.cs: + * pango/AttrFontDesc.cs: + * pango/AttrForeground.cs: + * pango/AttrLanguage.cs: + * pango/AttrLetterSpacing.cs: + * pango/AttrRise.cs: + * pango/AttrScale.cs: + * pango/AttrShape.cs: + * pango/AttrSize.cs: + * pango/AttrStretch.cs: + * pango/AttrStrikethrough.cs: + * pango/AttrStrikethroughColor.cs: + * pango/AttrStyle.cs: + * pango/AttrUnderline.cs: + * pango/AttrUnderlineColor.cs: + * pango/AttrVariant.cs: + * pango/AttrWeight.cs: subclasses of Attribute, with proper + constructors. These don't actually correspond one-to-one with + the underlying types, but they're nicer this way. + + * pango/Pango.metadata: Hide Attribute and its subclasses from the + generator. Also hide "Attr" (which previously contained + non-working badly-named static methods to create Attributes) + and AttrClass (which is not really useful outside of pango + itself). + + * pango/AttrIterator.custom: use Pango.Attribute.GetAttribute. + + * pango/glue/attribute.c: glue for Attribute and its subclasses + + [Fixes #52575 and its semi-dup #46552] + 2005-04-22 Dan Winship * gnome/Gnome.metadata: mark GnomeTriggerActionFunction's char** diff --git a/doc/ChangeLog b/doc/ChangeLog index 2fa2b7bd8..b7a1704d7 100644 --- a/doc/ChangeLog +++ b/doc/ChangeLog @@ -1,3 +1,7 @@ +2005-04-24 Dan Winship + + * en/Pango/Attribute.xml, etc: document new Attribute stuff. + 2005-04-21 Dan Winship * en/GLib/Marshaller.xml: update diff --git a/doc/en/Pango/Attr.xml b/doc/en/Pango/Attr.xml deleted file mode 100644 index c56ed1d2c..000000000 --- a/doc/en/Pango/Attr.xml +++ /dev/null @@ -1,307 +0,0 @@ - - - - pango-sharp - - - 0.0.0.0 - neutral - - - Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - - Static methods for attributes. - - - - System.Object - - - - - - - Method - - Pango.Attribute - - - - - - - - Create a new foreground color attribute. - the red value (ranging from 0 to 65535) - the green value - the blue value - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new font family attribute. - the family or comma separated list of families - a - - - - - - Method - - Pango.AttrType - - - - - - Allocate a new attribute type ID. - an identifier for the type. (Currently unused.) - the new type ID. - - - - - - Method - - Pango.Attribute - - - - - - Create a new font strike-through attribute. - - if the text should be struck-through. - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new font variant attribute (normal or small caps) - the - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new font stretch attribute - a - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new font slant style attribute. - the slant - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new font weight attribute. - a - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new underline-style object. - the underline style. - a - - - - - - Method - - Pango.Attribute - - - - - - - - Create a new background color attribute. - the red value (ranging from 0 to 65535) - the green value - the blue value - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new baseline displacement attribute. - the amount that the text should be displaced vertically, in 10'000ths of an em. Positive values displace the text upwards. - a - - - - - - Method - - Pango.Attribute - - - - - - Create a new font size scale attribute. - factor to scale the font - a - The base font for the affected text will have its size multiplied by . - - - - - Constructor - - - - Default constructor - a - - - - - - Method - - Pango.Attribute - - - - - - To be added - a - a - To be added - - - - - Method - - Pango.Attribute - - - - - - - - To be added - a - a - a - a - To be added - - - - - Method - - Pango.Attribute - - - - - - To be added - a - a - To be added - - - - - Method - - Pango.Attribute - - - - - - - - To be added - a - a - a - a - To be added - - - - diff --git a/doc/en/Pango/AttrBackground.xml b/doc/en/Pango/AttrBackground.xml new file mode 100644 index 000000000..eb2581edc --- /dev/null +++ b/doc/en/Pango/AttrBackground.xml @@ -0,0 +1,74 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing a background color + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + + + Creates a new background color attribute. + the red value + the green value + the blue value + a + + + + + + Constructor + + + + + + Creates a new background color attribute. + a + a + + + + + + Property + + Pango.Color + + + + The color represented by this attribute + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrClass.xml b/doc/en/Pango/AttrClass.xml deleted file mode 100644 index 209eca79a..000000000 --- a/doc/en/Pango/AttrClass.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - pango-sharp - - - 0.0.0.0 - neutral - - - Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - - Stores the type and operations for a particular type of attribute. - The functions in this structure should not be called directly. Instead, one should use the wrapper functions provided for . - - - System.ValueType - - - - - - - Field - - Pango.AttrClass - - - - Returns an empty - - - - - - Method - - Pango.AttrClass - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - - Field - - Pango.AttrType - - - - - the type ID for this attribute - - - - - \ No newline at end of file diff --git a/doc/en/Pango/AttrColor.xml b/doc/en/Pango/AttrColor.xml deleted file mode 100644 index 2a663f1d2..000000000 --- a/doc/en/Pango/AttrColor.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - pango-sharp - - - 0.0.0.0 - neutral - - - Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - - Used to represent attributes that are colors. - - - - System.ValueType - - - - - - - Field - - Pango.AttrColor - - - - Returns an empty - - - - - - Method - - Pango.AttrColor - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - - Field - - Pango.Attribute - - - - - the common portion of the attribute - - - - - - Field - - Pango.Color - - - - - the PangoColor which is the value of the attribute - - - - - \ No newline at end of file diff --git a/doc/en/Pango/AttrFallback.xml b/doc/en/Pango/AttrFallback.xml new file mode 100644 index 000000000..a0aa587ae --- /dev/null +++ b/doc/en/Pango/AttrFallback.xml @@ -0,0 +1,67 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing the font fallback state + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font fallback attribute + a + a + + If fallback is disabled, characters will only be used from + the closest matching font on the system. No fallback will + be done to other fonts on the system that might contain + the characters in the text. + + + + + + Property + + System.Boolean + + + + Whether or not font fallback is enabled + a + + If , characters will only be used + from the closest matching font on the system. If , fallback will be done to other fonts + on the system that might contain the characters in the + text. + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrFamily.xml b/doc/en/Pango/AttrFamily.xml new file mode 100644 index 000000000..f001bef1a --- /dev/null +++ b/doc/en/Pango/AttrFamily.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing a font family + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font family attribute + the family or comman-separated list of families + a + + + + + + Property + + System.String + + + + The font family, or comma-separated list of families + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrFloat.xml b/doc/en/Pango/AttrFloat.xml deleted file mode 100644 index 8b94e0bae..000000000 --- a/doc/en/Pango/AttrFloat.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - pango-sharp - - - 0.0.0.0 - neutral - - - Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - - Used to represent attributes with a float or double value. - - - - System.ValueType - - - - - - - Field - - Pango.AttrFloat - - - - Returns an empty - - - - - - Method - - Pango.AttrFloat - - - - - - Internal constructor - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - - Field - - Pango.Attribute - - - - - the common portion of the attribute - - - - - - Field - - System.Double - - - - - the value of the attribute - - - - - \ No newline at end of file diff --git a/doc/en/Pango/AttrFontDesc.xml b/doc/en/Pango/AttrFontDesc.xml index cabb43e65..e39897db1 100644 --- a/doc/en/Pango/AttrFontDesc.xml +++ b/doc/en/Pango/AttrFontDesc.xml @@ -10,86 +10,41 @@ Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - Used to store an attribute that sets all aspects of the font description at once. + An attribute that represents a - System.ValueType + Pango.Attribute - - - Field - - Pango.AttrFontDesc - - + + + Constructor + + + + - Returns an empty + Creates a new font description attribute + a + a - - - Method - - Pango.AttrFontDesc - - - - - - Create a new from the provided . - a - a new - - - - - - Method - - Pango.AttrFontDesc - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - + + Property Pango.FontDescription - - + - the font description which is the value of this attribute - a + The font description which is the value of this attribute a - - - Field - - Pango.Attribute - - - - - the common portion of the attribute - - - \ No newline at end of file diff --git a/doc/en/Pango/AttrForeground.xml b/doc/en/Pango/AttrForeground.xml new file mode 100644 index 000000000..5046bb85f --- /dev/null +++ b/doc/en/Pango/AttrForeground.xml @@ -0,0 +1,74 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing a foreground color + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + + + Creates a new foreground color attribute. + the red value + the green value + the blue value + a + + + + + + Constructor + + + + + + Creates a new foreground color attribute. + a + a + + + + + + Property + + Pango.Color + + + + The color represented by this attribute + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrInt.xml b/doc/en/Pango/AttrInt.xml deleted file mode 100644 index 3f759f552..000000000 --- a/doc/en/Pango/AttrInt.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - pango-sharp - - - 0.0.0.0 - neutral - - - Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - - Used to represent attributes with a integer or enumeration value. - - - - System.ValueType - - - - - - - Field - - Pango.AttrInt - - - - Returns an empty - - - - - - Method - - Pango.AttrInt - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - - Field - - Pango.Attribute - - - - - the common portion of the attribute - - - - - - Field - - System.Int32 - - - - - the value of the attribute - - - - - \ No newline at end of file diff --git a/doc/en/Pango/AttrLanguage.xml b/doc/en/Pango/AttrLanguage.xml index 22b745069..f3d3617e1 100644 --- a/doc/en/Pango/AttrLanguage.xml +++ b/doc/en/Pango/AttrLanguage.xml @@ -10,86 +10,41 @@ Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - Used to represent attributes that are languages. + An attribute that represents a language - System.ValueType + Pango.Attribute - - - Field - - Pango.AttrLanguage - - - - Returns an empty - - - - - - Method - - Pango.AttrLanguage - + + + Constructor + - Create a new from the provided + Creates a new language tag attribute a - a new + a - - - Method - - Pango.AttrLanguage - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - + + Property Pango.Language - - + - the PangoLanguage which is the value of the attribute - a + The language represented by this attribute a - - - Field - - Pango.Attribute - - - - - the common portion of the attribute - - - \ No newline at end of file diff --git a/doc/en/Pango/AttrLetterSpacing.xml b/doc/en/Pango/AttrLetterSpacing.xml new file mode 100644 index 000000000..902dc9145 --- /dev/null +++ b/doc/en/Pango/AttrLetterSpacing.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing letter spacing + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new letter-spacing attribute + the amount of extra space to add between letters, in Pango units + a + + + + + + Property + + System.Int32 + + + + The amount of extra space to add between letters, in Pango units + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrRise.xml b/doc/en/Pango/AttrRise.xml new file mode 100644 index 000000000..82438322f --- /dev/null +++ b/doc/en/Pango/AttrRise.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing baseline displacement + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new baseline displacement attribute + the amount that the text should be displaced vertically, in Pango units. Positive values displace the text upwards + a + + + + + + Property + + System.Int32 + + + + The amount that the text should be displaced vertically, in Pango units. Positive values displace the text upwards + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrScale.xml b/doc/en/Pango/AttrScale.xml new file mode 100644 index 000000000..7cfdb04dd --- /dev/null +++ b/doc/en/Pango/AttrScale.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing a font size scaling factor + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font size scale attribute + the factor to scale the font by + a + + + + + + Property + + System.Double + + + + The factor to scale the font by + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrShape.xml b/doc/en/Pango/AttrShape.xml index 97be72717..9b0310cb0 100644 --- a/doc/en/Pango/AttrShape.xml +++ b/doc/en/Pango/AttrShape.xml @@ -10,136 +10,61 @@ Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - Used to represent attributes which impose shape restrictions. + An attribute that imposes a shape restriction. - System.ValueType + Pango.Attribute - - - Field - - Pango.AttrShape - - - - Returns an empty - - - - - - Method - - Pango.AttrShape - + + + Constructor + - Creates a new from the provided s. - the ink rectangle to restrict to - the logical rectangle to restrict to - a new - - - - - - Method - - Pango.AttrShape - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - - Field - - Pango.Attribute - - - - - the common portion of the attribute - + Creates a new shape attribute + a + a + a + + A shape is used to impose a particular ink and logical + rectangle on the result of shaping a particular glyph. This + might be used, for instance, for embedding a picture or a + widget inside a . + - - Field + + Property Pango.Rectangle - - + - the ink rectangle to restrict to + The ink rectangle to restrict to + a - - Field + + Property Pango.Rectangle - - + - the logical rectangle to restrict to + The logical rectangle to restrict to + a - - - Field - - System.IntPtr - - - - - To be added - To be added - - - - - Method - - Pango.AttrShape - - - - - - - - - - To be added - a - a - a - a - a - a - To be added - - \ No newline at end of file diff --git a/doc/en/Pango/AttrSize.xml b/doc/en/Pango/AttrSize.xml index d7bb4a48a..75269cf03 100644 --- a/doc/en/Pango/AttrSize.xml +++ b/doc/en/Pango/AttrSize.xml @@ -9,100 +9,74 @@ Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - To be added - To be added + An attribute that represents a font size. + - System.ValueType + Pango.Attribute - - - Field - - Pango.AttrSize - + + + Constructor + + - To be added - To be added + Creates a new font-size attribute in fractional points + the font size, in units of + a + - - - Field - - Pango.Attribute - + + + Constructor + + + - To be added - To be added + Creates a new font-size attribute in Pango or device units + the font size, in Pango or device units + if , is in device units + a + - - Field + + Property System.Int32 - - + - To be added - To be added + The font size + a + + If is , this is the font size in device units. + If it is , this is the font size + in units of 1/ of a + point. + - - - Method + + + Property - Pango.AttrSize + System.Boolean - - - + - To be added - a - a - To be added - - - - - Method - - Pango.AttrSize - - - - - - To be added - a - a - To be added - - - - - Method - - Pango.AttrSize - - - - - - To be added - a - a - To be added + Whether or not is in device units + a + diff --git a/doc/en/Pango/AttrStretch.xml b/doc/en/Pango/AttrStretch.xml new file mode 100644 index 000000000..8ad6a980e --- /dev/null +++ b/doc/en/Pango/AttrStretch.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing font stretch + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font stretch attribute + the stretch + a + + + + + + Property + + Pango.Stretch + + + + The font stretch + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrStrikethrough.xml b/doc/en/Pango/AttrStrikethrough.xml new file mode 100644 index 000000000..d56789f99 --- /dev/null +++ b/doc/en/Pango/AttrStrikethrough.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute indicating whether or not text is struck-through + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font strike-through attribute + if the text should be struck-through + a + + + + + + Property + + System.Boolean + + + + Whether or not the text is struck-through + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrStrikethroughColor.xml b/doc/en/Pango/AttrStrikethroughColor.xml new file mode 100644 index 000000000..940e6c62f --- /dev/null +++ b/doc/en/Pango/AttrStrikethroughColor.xml @@ -0,0 +1,74 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing the color of a strikethrough line + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + + + Creates a new strikethrough color attribute. + the red value + the green value + the blue value + a + + + + + + Constructor + + + + + + Creates a new strikethrough color attribute. + a + a + + + + + + Property + + Pango.Color + + + + The color represented by this attribute + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrString.xml b/doc/en/Pango/AttrString.xml deleted file mode 100644 index d99cc016a..000000000 --- a/doc/en/Pango/AttrString.xml +++ /dev/null @@ -1,77 +0,0 @@ - - - - pango-sharp - - - 0.0.0.0 - neutral - - - Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - - Used to represent attributes with a string value. - - - - System.ValueType - - - - - - - Field - - Pango.AttrString - - - - Returns an empty - - - - - - Method - - Pango.AttrString - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - - - - Field - - Pango.Attribute - - - - - the common portion of the attribute - - - - - - Field - - System.String - - - - - the string which is the value of the attribute - - - - - \ No newline at end of file diff --git a/doc/en/Pango/AttrStyle.xml b/doc/en/Pango/AttrStyle.xml new file mode 100644 index 000000000..e65d6056d --- /dev/null +++ b/doc/en/Pango/AttrStyle.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing a + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font slant syle attribute + the slant style + a + + + + + + Property + + Pango.Style + + + + The font slant style + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrUnderline.xml b/doc/en/Pango/AttrUnderline.xml new file mode 100644 index 000000000..7b448f4cb --- /dev/null +++ b/doc/en/Pango/AttrUnderline.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing underlining + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new underline-style object + the underline style + a + + + + + + Property + + Pango.Underline + + + + The underline style + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrUnderlineColor.xml b/doc/en/Pango/AttrUnderlineColor.xml new file mode 100644 index 000000000..414023b82 --- /dev/null +++ b/doc/en/Pango/AttrUnderlineColor.xml @@ -0,0 +1,74 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing the color of an underline + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + + + Creates a new underline color attribute. + the red value + the green value + the blue value + a + + + + + + Constructor + + + + + + Creates a new underline color attribute. + a + a + + + + + + Property + + Pango.Color + + + + The color represented by this attribute + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrVariant.xml b/doc/en/Pango/AttrVariant.xml new file mode 100644 index 000000000..ea17edae1 --- /dev/null +++ b/doc/en/Pango/AttrVariant.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font variant attribute + the variant + a + + + + + + Property + + Pango.Variant + + + + The variant + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/AttrWeight.xml b/doc/en/Pango/AttrWeight.xml new file mode 100644 index 000000000..4c82dfbfc --- /dev/null +++ b/doc/en/Pango/AttrWeight.xml @@ -0,0 +1,56 @@ + + + + pango-sharp + [00 24 00 00 04 80 00 00 94 00 00 00 06 02 00 00 00 24 00 00 52 53 41 31 00 04 00 00 01 00 01 00 71 EB 6C 55 75 52 9C BF 72 44 F7 A6 EA 05 62 84 F9 EA E0 3B CF F2 CC 13 2C 9C 49 0A B3 09 EA B0 B5 6B CE 44 9D F5 03 D9 C0 A8 1E 52 05 85 CD BE 70 E2 FB 90 43 4B AC 04 FA 62 22 A8 00 98 B7 A1 A7 B3 AF 99 1A 41 23 24 BB 43 25 F6 B8 65 BB 64 EB F6 D1 C2 06 D5 73 2D DF BC 70 A7 38 9E E5 3E 0C 24 6E 32 79 74 1A D0 05 03 E4 98 42 E1 9B F3 7B 19 8B 40 21 26 CB 36 89 C2 EA 64 96 A4 7C B4] + 2.0.0.0 + neutral + + + Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. + + An attribute representing + + + + Pango.Attribute + + + + GLib.IWrapper + + + System.IDisposable + + + + + + + Constructor + + + + + + Creates a new font weight attribute + the weight + a + + + + + + Property + + Pango.Weight + + + + The weight + a + + + + + \ No newline at end of file diff --git a/doc/en/Pango/Attribute.xml b/doc/en/Pango/Attribute.xml index 6904238e5..f3a06a1da 100644 --- a/doc/en/Pango/Attribute.xml +++ b/doc/en/Pango/Attribute.xml @@ -10,43 +10,15 @@ Gtk# is thread aware, but not thread safe; See the Gtk# Thread Programming for details. - This structure represents the common portions of all attributes - Particular types of attributes include this structure as their initial portion. The common portion of the attribute holds the range to which the value in the type-specific part of the attribute applies. + This is the base class for all Pango text attributes + - System.ValueType + System.Object - - - Field - - Pango.Attribute - - - - Returns an empty - - - - - - Method - - Pango.Attribute - - - - - - Internal method - an object of type - an object of type - This is an internal method, and should not be used by user code. - - Method @@ -64,18 +36,6 @@ This compares only the actual value of the two attributes and not the ranges that the attributes apply to. - - - Method - - System.Void - - - - Destroy a and free all associated memory. - - - Method @@ -89,42 +49,109 @@ - - + + Property - Pango.AttrClass + GLib.GType + - the class structure holding information about the type of the attribute - an object of type + GType property + a + Returns the value for + + + + + Property + + System.IntPtr + + + + Pointer to the raw PangoAttribute structure associated with this object. + a + To be added + + + + + Property + + Pango.AttrType + + + + The attribute type + a - - Field + + Property System.UInt32 - - + the start index of the range (in bytes). + a - - Field + + Property System.UInt32 - - + end index of the range. - The character containing this byte index is not included in the range. + a + The character containing this byte index is not included in the range. + + + + + Method + + Pango.Attribute + + + + + + Gets an Attribute or Attribute subclass for a native PangoAttribute pointer + a + a + + + + + + Method + + System.Void + + + + Finalizer + + + + + + Method + + System.Void + + + + Dispose method + diff --git a/pango/AttrBackground.cs b/pango/AttrBackground.cs new file mode 100644 index 000000000..2c751e4e4 --- /dev/null +++ b/pango/AttrBackground.cs @@ -0,0 +1,44 @@ +// Pango.AttrBackground - Pango.Attribute for background color +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrBackground : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_background_new (ushort red, ushort green, ushort blue); + + public AttrBackground (ushort red, ushort green, ushort blue) : this (pango_attr_background_new (red, green, blue)) {} + + public AttrBackground (Pango.Color color) : this (pango_attr_background_new (color.Red, color.Green, color.Blue)) {} + + internal AttrBackground (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern Pango.Color pangosharp_attr_color_get_color (IntPtr raw); + + public Pango.Color Color { + get { + return pangosharp_attr_color_get_color (Handle); + } + } + } +} diff --git a/pango/AttrFallback.cs b/pango/AttrFallback.cs new file mode 100644 index 000000000..d206d72b3 --- /dev/null +++ b/pango/AttrFallback.cs @@ -0,0 +1,42 @@ +// Pango.AttrFallback - Pango.Attribute for font fallback +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrFallback : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_fallback_new (bool fallback); + + public AttrFallback (bool fallback) : this (pango_attr_fallback_new (fallback)) {} + + internal AttrFallback (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public bool Fallback { + get { + return pangosharp_attr_int_get_value (Handle) != 0; + } + } + } +} diff --git a/pango/AttrFamily.cs b/pango/AttrFamily.cs new file mode 100644 index 000000000..99bf037cd --- /dev/null +++ b/pango/AttrFamily.cs @@ -0,0 +1,51 @@ +// Pango.AttrFamily - Pango.Attribute for font families +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrFamily : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_family_new (IntPtr family); + + public AttrFamily (string family) : base (NewAttrFamily (family)) {} + + static IntPtr NewAttrFamily (string family) + { + IntPtr family_raw = GLib.Marshaller.StringToPtrGStrdup (family); + IntPtr attr_raw = pango_attr_family_new (family_raw); + GLib.Marshaller.Free (family_raw); + return attr_raw; + } + + internal AttrFamily (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern IntPtr pangosharp_attr_string_get_value (IntPtr raw); + + public string Family { + get { + IntPtr raw_family = pangosharp_attr_string_get_value (Handle); + return GLib.Marshaller.Utf8PtrToString (raw_family); + } + } + } +} diff --git a/pango/AttrFontDesc.cs b/pango/AttrFontDesc.cs new file mode 100644 index 000000000..3d77f2fb3 --- /dev/null +++ b/pango/AttrFontDesc.cs @@ -0,0 +1,43 @@ +// Pango.AttrFontDesc - Pango.Attribute for Pango.FontDescription +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrFontDesc : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_font_desc_new (IntPtr font_desc); + + public AttrFontDesc (Pango.FontDescription font_desc) : this (pango_attr_font_desc_new (font_desc.Handle)) {} + + internal AttrFontDesc (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern IntPtr pangosharp_attr_font_desc_get_desc (IntPtr raw); + + public Pango.FontDescription Desc { + get { + IntPtr raw_ret = pangosharp_attr_font_desc_get_desc (Handle); + return new Pango.FontDescription (raw_ret); + } + } + } +} diff --git a/pango/AttrForeground.cs b/pango/AttrForeground.cs new file mode 100644 index 000000000..07aeeb51e --- /dev/null +++ b/pango/AttrForeground.cs @@ -0,0 +1,44 @@ +// Pango.AttrForeground - Pango.Attribute for foreground color +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrForeground : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_foreground_new (ushort red, ushort green, ushort blue); + + public AttrForeground (ushort red, ushort green, ushort blue) : this (pango_attr_foreground_new (red, green, blue)) {} + + public AttrForeground (Pango.Color color) : this (pango_attr_foreground_new (color.Red, color.Green, color.Blue)) {} + + internal AttrForeground (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern Pango.Color pangosharp_attr_color_get_color (IntPtr raw); + + public Pango.Color Color { + get { + return pangosharp_attr_color_get_color (Handle); + } + } + } +} diff --git a/pango/AttrIterator.custom b/pango/AttrIterator.custom index ce30c7fbe..262ea4d54 100644 --- a/pango/AttrIterator.custom +++ b/pango/AttrIterator.custom @@ -37,8 +37,8 @@ GLib.SList list = new GLib.SList (list_handle); extra_attrs = new Pango.Attribute [list.Count]; int i = 0; - foreach (Pango.Attribute attr in list) - extra_attrs [i++] = attr; + foreach (IntPtr raw_attr in list) + extra_attrs [i++] = Pango.Attribute.GetAttribute (raw_attr); } [DllImport("libpango-1.0-0.dll")] @@ -52,8 +52,8 @@ GLib.SList list = new GLib.SList (list_handle); Pango.Attribute[] attrs = new Pango.Attribute [list.Count]; int i = 0; - foreach (Pango.Attribute attr in list) - attrs [i++] = attr; + foreach (IntPtr raw_attr in list) + attrs [i++] = Pango.Attribute.GetAttribute (raw_attr); return attrs; } } diff --git a/pango/AttrLanguage.cs b/pango/AttrLanguage.cs new file mode 100644 index 000000000..d4207bea6 --- /dev/null +++ b/pango/AttrLanguage.cs @@ -0,0 +1,43 @@ +// Pango.AttrLanguage - Pango.Attribute for Pango.Language +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrLanguage : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_language_new (IntPtr language); + + public AttrLanguage (Pango.Language language) : this (pango_attr_language_new (language.Handle)) {} + + internal AttrLanguage (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern IntPtr pangosharp_attr_language_get_value (IntPtr raw); + + public Pango.Language Language { + get { + IntPtr raw_ret = pangosharp_attr_language_get_value (Handle); + return new Pango.Language (raw_ret); + } + } + } +} diff --git a/pango/AttrLetterSpacing.cs b/pango/AttrLetterSpacing.cs new file mode 100644 index 000000000..93720a26f --- /dev/null +++ b/pango/AttrLetterSpacing.cs @@ -0,0 +1,42 @@ +// Pango.AttrLetterSpacing - Pango.Attribute for baseline displacement +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrLetterSpacing : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_letter_spacing_new (int letter_spacing); + + public AttrLetterSpacing (int letter_spacing) : this (pango_attr_letter_spacing_new (letter_spacing)) {} + + internal AttrLetterSpacing (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public int LetterSpacing { + get { + return pangosharp_attr_int_get_value (Handle); + } + } + } +} diff --git a/pango/AttrRise.cs b/pango/AttrRise.cs new file mode 100644 index 000000000..a981331af --- /dev/null +++ b/pango/AttrRise.cs @@ -0,0 +1,42 @@ +// Pango.AttrRise - Pango.Attribute for baseline displacement +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrRise : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_rise_new (int rise); + + public AttrRise (int rise) : this (pango_attr_rise_new (rise)) {} + + internal AttrRise (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public int Rise { + get { + return pangosharp_attr_int_get_value (Handle); + } + } + } +} diff --git a/pango/AttrScale.cs b/pango/AttrScale.cs new file mode 100644 index 000000000..2d824c44b --- /dev/null +++ b/pango/AttrScale.cs @@ -0,0 +1,42 @@ +// Pango.AttrScale - Pango.Attribute for font size scale +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrScale : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_scale_new (double scale); + + public AttrScale (double scale) : this (pango_attr_scale_new (scale)) {} + + internal AttrScale (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern double pangosharp_attr_float_get_value (IntPtr raw); + + public double Scale { + get { + return pangosharp_attr_float_get_value (Handle); + } + } + } +} diff --git a/pango/AttrShape.cs b/pango/AttrShape.cs new file mode 100644 index 000000000..f85e976ed --- /dev/null +++ b/pango/AttrShape.cs @@ -0,0 +1,51 @@ +// Pango.AttrShape - Pango.Attribute for shape restrictions +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrShape : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_shape_new (ref Pango.Rectangle ink_rect, ref Pango.Rectangle logical_rect); + + public AttrShape (Pango.Rectangle ink_rect, Pango.Rectangle logical_rect) : this (pango_attr_shape_new (ref ink_rect, ref logical_rect)) {} + + internal AttrShape (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern Pango.Rectangle pangosharp_attr_shape_get_ink_rect (IntPtr raw); + + public Pango.Rectangle InkRect { + get { + return pangosharp_attr_shape_get_ink_rect (Handle); + } + } + + [DllImport("pangosharpglue-2")] + static extern Pango.Rectangle pangosharp_attr_shape_get_logical_rect (IntPtr raw); + + public Pango.Rectangle LogicalRect { + get { + return pangosharp_attr_shape_get_logical_rect (Handle); + } + } + } +} diff --git a/pango/AttrSize.cs b/pango/AttrSize.cs new file mode 100644 index 000000000..2f3592356 --- /dev/null +++ b/pango/AttrSize.cs @@ -0,0 +1,56 @@ +// Pango.AttrSize - Pango.Attribute for font size +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrSize : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_size_new (int size); + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_size_new_absolute (int size); + + public AttrSize (int size) : this (pango_attr_size_new (size)) {} + + public AttrSize (int size, bool absolute) : this (absolute ? pango_attr_size_new (size) : pango_attr_size_new_absolute (size)) {} + + internal AttrSize (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_size_get_size (IntPtr raw); + + public int Size { + get { + return pangosharp_attr_size_get_size (Handle); + } + } + + [DllImport("pangosharpglue-2")] + static extern bool pangosharp_attr_size_get_absolute (IntPtr raw); + + public bool Absolute { + get { + return pangosharp_attr_size_get_absolute (Handle); + } + } + } +} diff --git a/pango/AttrStretch.cs b/pango/AttrStretch.cs new file mode 100644 index 000000000..f47b28fe7 --- /dev/null +++ b/pango/AttrStretch.cs @@ -0,0 +1,42 @@ +// Pango.AttrStretch - Pango.Attribute for Pango.Stretch +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrStretch : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_stretch_new (Pango.Stretch stretch); + + public AttrStretch (Pango.Stretch stretch) : this (pango_attr_stretch_new (stretch)) {} + + internal AttrStretch (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public Pango.Stretch Stretch { + get { + return (Pango.Stretch)pangosharp_attr_int_get_value (Handle); + } + } + } +} diff --git a/pango/AttrStrikethrough.cs b/pango/AttrStrikethrough.cs new file mode 100644 index 000000000..46b2b6403 --- /dev/null +++ b/pango/AttrStrikethrough.cs @@ -0,0 +1,42 @@ +// Pango.AttrStrikethrough - Pango.Attribute for strikethrough +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrStrikethrough : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_strikethrough_new (bool strikethrough); + + public AttrStrikethrough (bool strikethrough) : this (pango_attr_strikethrough_new (strikethrough)) {} + + internal AttrStrikethrough (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public bool Strikethrough { + get { + return pangosharp_attr_int_get_value (Handle) != 0; + } + } + } +} diff --git a/pango/AttrStrikethroughColor.cs b/pango/AttrStrikethroughColor.cs new file mode 100644 index 000000000..9be70aaf2 --- /dev/null +++ b/pango/AttrStrikethroughColor.cs @@ -0,0 +1,44 @@ +// Pango.AttrStrikethroughColor - Pango.Attribute for strikethrough color +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrStrikethroughColor : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_strikethrough_color_new (ushort red, ushort green, ushort blue); + + public AttrStrikethroughColor (ushort red, ushort green, ushort blue) : this (pango_attr_strikethrough_color_new (red, green, blue)) {} + + public AttrStrikethroughColor (Pango.Color color) : this (pango_attr_strikethrough_color_new (color.Red, color.Green, color.Blue)) {} + + internal AttrStrikethroughColor (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern Pango.Color pangosharp_attr_color_get_color (IntPtr raw); + + public Pango.Color Color { + get { + return pangosharp_attr_color_get_color (Handle); + } + } + } +} diff --git a/pango/AttrStyle.cs b/pango/AttrStyle.cs new file mode 100644 index 000000000..b2b758c6a --- /dev/null +++ b/pango/AttrStyle.cs @@ -0,0 +1,42 @@ +// Pango.AttrStyle - Pango.Attribute for Pango.Style +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrStyle : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_style_new (Pango.Style style); + + public AttrStyle (Pango.Style style) : this (pango_attr_style_new (style)) {} + + internal AttrStyle (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public Pango.Style Style { + get { + return (Pango.Style)pangosharp_attr_int_get_value (Handle); + } + } + } +} diff --git a/pango/AttrUnderline.cs b/pango/AttrUnderline.cs new file mode 100644 index 000000000..d63a0f514 --- /dev/null +++ b/pango/AttrUnderline.cs @@ -0,0 +1,42 @@ +// Pango.AttrUnderline - Pango.Attribute for Pango.Underline +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrUnderline : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_underline_new (Pango.Underline underline); + + public AttrUnderline (Pango.Underline underline) : this (pango_attr_underline_new (underline)) {} + + internal AttrUnderline (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public Pango.Underline Underline { + get { + return (Pango.Underline)pangosharp_attr_int_get_value (Handle); + } + } + } +} diff --git a/pango/AttrUnderlineColor.cs b/pango/AttrUnderlineColor.cs new file mode 100644 index 000000000..540a1e7ff --- /dev/null +++ b/pango/AttrUnderlineColor.cs @@ -0,0 +1,44 @@ +// Pango.AttrUnderlineColor - Pango.Attribute for underline color +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrUnderlineColor : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_underline_color_new (ushort red, ushort green, ushort blue); + + public AttrUnderlineColor (ushort red, ushort green, ushort blue) : this (pango_attr_underline_color_new (red, green, blue)) {} + + public AttrUnderlineColor (Pango.Color color) : this (pango_attr_underline_color_new (color.Red, color.Green, color.Blue)) {} + + internal AttrUnderlineColor (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern Pango.Color pangosharp_attr_color_get_color (IntPtr raw); + + public Pango.Color Color { + get { + return pangosharp_attr_color_get_color (Handle); + } + } + } +} diff --git a/pango/AttrVariant.cs b/pango/AttrVariant.cs new file mode 100644 index 000000000..4c313a060 --- /dev/null +++ b/pango/AttrVariant.cs @@ -0,0 +1,42 @@ +// Pango.AttrVariant - Pango.Attribute for Pango.Variant +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrVariant : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_variant_new (Pango.Variant variant); + + public AttrVariant (Pango.Variant variant) : this (pango_attr_variant_new (variant)) {} + + internal AttrVariant (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public Pango.Variant Variant { + get { + return (Pango.Variant)pangosharp_attr_int_get_value (Handle); + } + } + } +} diff --git a/pango/AttrWeight.cs b/pango/AttrWeight.cs new file mode 100644 index 000000000..d493beb81 --- /dev/null +++ b/pango/AttrWeight.cs @@ -0,0 +1,42 @@ +// Pango.AttrWeight - Pango.Attribute for Pango.Weight +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class AttrWeight : Attribute { + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attr_weight_new (Pango.Weight weight); + + public AttrWeight (Pango.Weight weight) : this (pango_attr_weight_new (weight)) {} + + internal AttrWeight (IntPtr raw) : base (raw) {} + + [DllImport("pangosharpglue-2")] + static extern int pangosharp_attr_int_get_value (IntPtr raw); + + public Pango.Weight Weight { + get { + return (Pango.Weight)pangosharp_attr_int_get_value (Handle); + } + } + } +} diff --git a/pango/Attribute.cs b/pango/Attribute.cs new file mode 100644 index 000000000..7393935e7 --- /dev/null +++ b/pango/Attribute.cs @@ -0,0 +1,161 @@ +// Pango.Attribute - Attribute "base class" +// +// Copyright (c) 2005 Novell, Inc. +// +// This program is free software; you can redistribute it and/or +// modify it under the terms of version 2 of the Lesser GNU General +// Public License as published by the Free Software Foundation. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// Lesser General Public License for more details. +// +// You should have received a copy of the GNU Lesser General Public +// License along with this program; if not, write to the +// Free Software Foundation, Inc., 59 Temple Place - Suite 330, +// Boston, MA 02111-1307, USA. + +namespace Pango { + + using System; + using System.Runtime.InteropServices; + + public class Attribute : GLib.IWrapper, IDisposable { + + IntPtr raw; + + internal Attribute (IntPtr raw) + { + this.raw = raw; + } + + [DllImport("pangosharpglue-2")] + static extern Pango.AttrType pangosharp_attribute_get_attr_type (IntPtr raw); + + public static Attribute GetAttribute (IntPtr raw) + { + switch (pangosharp_attribute_get_attr_type (raw)) { + case Pango.AttrType.Language: + return new AttrLanguage (raw); + case Pango.AttrType.Family: + return new AttrFamily (raw); + case Pango.AttrType.Style: + return new AttrStyle (raw); + case Pango.AttrType.Weight: + return new AttrWeight (raw); + case Pango.AttrType.Variant: + return new AttrVariant (raw); + case Pango.AttrType.Stretch: + return new AttrStretch (raw); + case Pango.AttrType.Size: + return new AttrSize (raw); + case Pango.AttrType.FontDesc: + return new AttrFontDesc (raw); + case Pango.AttrType.Foreground: + return new AttrForeground (raw); + case Pango.AttrType.Background: + return new AttrBackground (raw); + case Pango.AttrType.Underline: + return new AttrUnderline (raw); + case Pango.AttrType.Strikethrough: + return new AttrStrikethrough (raw); + case Pango.AttrType.Rise: + return new AttrRise (raw); + case Pango.AttrType.Shape: + return new AttrShape (raw); + case Pango.AttrType.Scale: + return new AttrScale (raw); + case Pango.AttrType.Fallback: + return new AttrFallback (raw); + case Pango.AttrType.LetterSpacing: + return new AttrLetterSpacing (raw); + case Pango.AttrType.UnderlineColor: + return new AttrUnderlineColor (raw); + case Pango.AttrType.StrikethroughColor: + return new AttrStrikethroughColor (raw); + default: + return new Attribute (raw); + } + } + + ~Attribute () + { + Dispose (); + } + + [DllImport("libpango-1.0-0.dll")] + static extern void pango_attribute_destroy (IntPtr raw); + + public void Dispose () + { + if (raw != IntPtr.Zero) { + pango_attribute_destroy (raw); + raw = IntPtr.Zero; + } + GC.SuppressFinalize (this); + } + + public IntPtr Handle { + get { + return raw; + } + } + + public static GLib.GType GType { + get { + return GLib.GType.Pointer; + } + } + + public Pango.AttrType Type { + get { + return pangosharp_attribute_get_attr_type (raw); + } + } + + [DllImport("pangosharpglue-2")] + static extern uint pangosharp_attribute_get_start_index (IntPtr raw); + + [DllImport("pangosharpglue-2")] + static extern void pangosharp_attribute_set_start_index (IntPtr raw, uint index); + + public uint StartIndex { + get { + return pangosharp_attribute_get_start_index (raw); + } + set { + pangosharp_attribute_set_start_index (raw, value); + } + } + + [DllImport("pangosharpglue-2")] + static extern uint pangosharp_attribute_get_end_index (IntPtr raw); + + [DllImport("pangosharpglue-2")] + static extern void pangosharp_attribute_set_end_index (IntPtr raw, uint index); + + public uint EndIndex { + get { + return pangosharp_attribute_get_end_index (raw); + } + set { + pangosharp_attribute_set_end_index (raw, value); + } + } + + [DllImport("libpango-1.0-0.dll")] + static extern IntPtr pango_attribute_copy (IntPtr raw); + + public Pango.Attribute Copy () { + return GetAttribute (pango_attribute_copy (raw)); + } + + [DllImport("libpango-1.0-0.dll")] + static extern bool pango_attribute_equal (IntPtr raw1, IntPtr raw2); + + public bool Equal (Pango.Attribute attr2) { + return pango_attribute_equal (raw, attr2.raw); + } + } +} diff --git a/pango/Makefile.am b/pango/Makefile.am index bb94bff88..1e0b26103 100644 --- a/pango/Makefile.am +++ b/pango/Makefile.am @@ -2,10 +2,30 @@ SUBDIRS = . glue pkg = pango METADATA = Pango.metadata -SYMBOLS = +SYMBOLS = pango-symbols.xml references = ../glib/glib-sharp.dll -sources = \ +sources = \ + Attribute.cs \ + AttrBackground.cs \ + AttrFallback.cs \ + AttrFamily.cs \ + AttrFontDesc.cs \ + AttrForeground.cs \ + AttrLanguage.cs \ + AttrLetterSpacing.cs \ + AttrRise.cs \ + AttrScale.cs \ + AttrShape.cs \ + AttrSize.cs \ + AttrStretch.cs \ + AttrStrikethroughColor.cs \ + AttrStrikethrough.cs \ + AttrStyle.cs \ + AttrUnderlineColor.cs \ + AttrUnderline.cs \ + AttrVariant.cs \ + AttrWeight.cs \ Scale.cs customs = \ diff --git a/pango/Pango.metadata b/pango/Pango.metadata index b56856f41..21db0b7d4 100644 --- a/pango/Pango.metadata +++ b/pango/Pango.metadata @@ -4,6 +4,7 @@ 1 1 1 + 1 1 1 1 @@ -29,8 +30,18 @@ 1 1 1 + 1 + 1 + 1 + 1 + 1 + 1 1 1 + 1 + 1 + 1 + 1 1 1 1 diff --git a/pango/glue/Makefile.am b/pango/glue/Makefile.am index 2b976d568..5ff422c02 100644 --- a/pango/glue/Makefile.am +++ b/pango/glue/Makefile.am @@ -1,6 +1,7 @@ lib_LTLIBRARIES = libpangosharpglue-2.la libpangosharpglue_2_la_SOURCES = \ + attribute.c \ layoutline.c # Adding a new glue file? diff --git a/pango/glue/attribute.c b/pango/glue/attribute.c new file mode 100644 index 000000000..d94035bf2 --- /dev/null +++ b/pango/glue/attribute.c @@ -0,0 +1,130 @@ +/* attribute.c : Glue to access fields in PangoAttribute and + * subclasses. + * + * Copyright (c) 2005 Novell, Inc. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of version 2 of the Lesser GNU General + * Public License as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this program; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#include + +/* Forward declarations */ +PangoAttrType pangosharp_attribute_get_attr_type (PangoAttribute *attr); +guint pangosharp_attribute_get_start_index (PangoAttribute *attr); +void pangosharp_attribute_set_start_index (PangoAttribute *attr, guint ind); +guint pangosharp_attribute_get_end_index (PangoAttribute *attr); +void pangosharp_attribute_set_end_index (PangoAttribute *attr, guint ind); +const char *pangosharp_attr_string_get_value (PangoAttrString *attr); +PangoLanguage *pangosharp_attr_language_get_value (PangoAttrLanguage *attr); +PangoColor pangosharp_attr_color_get_color (PangoAttrColor *attr); +int pangosharp_attr_int_get_value (PangoAttrInt *attr); +double pangosharp_attr_float_get_value (PangoAttrFloat *attr); +PangoFontDescription *pangosharp_attr_font_desc_get_desc (PangoAttrFontDesc *attr); +PangoRectangle pangosharp_attr_shape_get_ink_rect (PangoAttrShape *attr); +PangoRectangle pangosharp_attr_shape_get_logical_rect (PangoAttrShape *attr); +int pangosharp_attr_size_get_size (PangoAttrSize *attr); +gboolean pangosharp_attr_size_get_absolute (PangoAttrSize *attr); +/* */ + +PangoAttrType +pangosharp_attribute_get_attr_type (PangoAttribute *attr) +{ + return attr->klass->type; +} + +guint +pangosharp_attribute_get_start_index (PangoAttribute *attr) +{ + return attr->start_index; +} + +void +pangosharp_attribute_set_start_index (PangoAttribute *attr, guint ind) +{ + attr->start_index = ind; +} + +guint +pangosharp_attribute_get_end_index (PangoAttribute *attr) +{ + return attr->end_index; +} + +void +pangosharp_attribute_set_end_index (PangoAttribute *attr, guint ind) +{ + attr->end_index = ind; +} + +const char * +pangosharp_attr_string_get_value (PangoAttrString *attr) +{ + return attr->value; +} + +PangoLanguage * +pangosharp_attr_language_get_value (PangoAttrLanguage *attr) +{ + return attr->value; +} + +PangoColor +pangosharp_attr_color_get_color (PangoAttrColor *attr) +{ + return attr->color; +} + +int +pangosharp_attr_int_get_value (PangoAttrInt *attr) +{ + return attr->value; +} + +double +pangosharp_attr_float_get_value (PangoAttrFloat *attr) +{ + return attr->value; +} + +PangoFontDescription * +pangosharp_attr_font_desc_get_desc (PangoAttrFontDesc *attr) +{ + return attr->desc; +} + +PangoRectangle +pangosharp_attr_shape_get_ink_rect (PangoAttrShape *attr) +{ + return attr->ink_rect; +} + +PangoRectangle +pangosharp_attr_shape_get_logical_rect (PangoAttrShape *attr) +{ + return attr->logical_rect; +} + +int +pangosharp_attr_size_get_size (PangoAttrSize *attr) +{ + return attr->size; +} + +gboolean +pangosharp_attr_size_get_absolute (PangoAttrSize *attr) +{ + return attr->absolute; +} + diff --git a/pango/glue/makefile.win32 b/pango/glue/makefile.win32 index 2614d047e..6acc93d6c 100644 --- a/pango/glue/makefile.win32 +++ b/pango/glue/makefile.win32 @@ -4,6 +4,7 @@ CC=gcc -mno-cygwin -mms-bitfields DLLWRAP=dllwrap -mno-cygwin -mms-bitfields --target i386-mingw32 --export-all-symbols GLUE_OBJS = \ + attribute.c \ layoutline.o \ win32dll.o diff --git a/pango/pango-symbols.xml b/pango/pango-symbols.xml new file mode 100644 index 000000000..0dddeefab --- /dev/null +++ b/pango/pango-symbols.xml @@ -0,0 +1,5 @@ + + + + +