591 lines
27 KiB
C#
591 lines
27 KiB
C#
|
|
// This file was generated by the Gtk# code generator.
|
||
|
|
// Any changes made will be lost if regenerated.
|
||
|
|
|
||
|
|
namespace Pango {
|
||
|
|
|
||
|
|
using System;
|
||
|
|
using System.Collections;
|
||
|
|
using System.Collections.Generic;
|
||
|
|
using System.Runtime.InteropServices;
|
||
|
|
using static GLib.AbiStructExtension;
|
||
|
|
|
||
|
|
#region Autogenerated code
|
||
|
|
public partial class Layout : GLib.Object {
|
||
|
|
|
||
|
|
public Layout (IntPtr raw) : base(raw) {}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_new(IntPtr context);
|
||
|
|
static d_pango_layout_new pango_layout_new = FuncLoader.LoadFunction<d_pango_layout_new>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_new"));
|
||
|
|
|
||
|
|
public Layout (Pango.Context context) : base (IntPtr.Zero)
|
||
|
|
{
|
||
|
|
if (GetType () != typeof (Layout)) {
|
||
|
|
var vals = new List<GLib.Value> ();
|
||
|
|
var names = new List<string> ();
|
||
|
|
CreateNativeObject (names.ToArray (), vals.ToArray ());
|
||
|
|
return;
|
||
|
|
}
|
||
|
|
Raw = pango_layout_new(context == null ? IntPtr.Zero : context.Handle);
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
// Internal representation of the wrapped structure ABI.
|
||
|
|
static GLib.AbiStruct _class_abi = null;
|
||
|
|
static public unsafe new GLib.AbiStruct class_abi {
|
||
|
|
get {
|
||
|
|
if (_class_abi == null)
|
||
|
|
_class_abi = new GLib.AbiStruct (GLib.Object.class_abi.Fields);
|
||
|
|
|
||
|
|
return _class_abi;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
// End of the ABI representation.
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_context_changed(IntPtr raw);
|
||
|
|
static d_pango_layout_context_changed pango_layout_context_changed = FuncLoader.LoadFunction<d_pango_layout_context_changed>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_context_changed"));
|
||
|
|
|
||
|
|
public void ContextChanged() {
|
||
|
|
pango_layout_context_changed(Handle);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_copy(IntPtr raw);
|
||
|
|
static d_pango_layout_copy pango_layout_copy = FuncLoader.LoadFunction<d_pango_layout_copy>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_copy"));
|
||
|
|
|
||
|
|
public Pango.Layout Copy() {
|
||
|
|
IntPtr raw_ret = pango_layout_copy(Handle);
|
||
|
|
Pango.Layout ret = GLib.Object.GetObject(raw_ret, true) as Pango.Layout;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_alignment(IntPtr raw);
|
||
|
|
static d_pango_layout_get_alignment pango_layout_get_alignment = FuncLoader.LoadFunction<d_pango_layout_get_alignment>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_alignment"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_alignment(IntPtr raw, int alignment);
|
||
|
|
static d_pango_layout_set_alignment pango_layout_set_alignment = FuncLoader.LoadFunction<d_pango_layout_set_alignment>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_alignment"));
|
||
|
|
|
||
|
|
public Pango.Alignment Alignment {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_alignment(Handle);
|
||
|
|
Pango.Alignment ret = (Pango.Alignment) raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_alignment(Handle, (int) value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_attributes(IntPtr raw);
|
||
|
|
static d_pango_layout_get_attributes pango_layout_get_attributes = FuncLoader.LoadFunction<d_pango_layout_get_attributes>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_attributes"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_attributes(IntPtr raw, IntPtr attrs);
|
||
|
|
static d_pango_layout_set_attributes pango_layout_set_attributes = FuncLoader.LoadFunction<d_pango_layout_set_attributes>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_attributes"));
|
||
|
|
|
||
|
|
public Pango.AttrList Attributes {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_attributes(Handle);
|
||
|
|
Pango.AttrList ret = raw_ret == IntPtr.Zero ? null : (Pango.AttrList) GLib.Opaque.GetOpaque (raw_ret, typeof (Pango.AttrList), false);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_attributes(Handle, value == null ? IntPtr.Zero : value.Handle);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate bool d_pango_layout_get_auto_dir(IntPtr raw);
|
||
|
|
static d_pango_layout_get_auto_dir pango_layout_get_auto_dir = FuncLoader.LoadFunction<d_pango_layout_get_auto_dir>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_auto_dir"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_auto_dir(IntPtr raw, bool auto_dir);
|
||
|
|
static d_pango_layout_set_auto_dir pango_layout_set_auto_dir = FuncLoader.LoadFunction<d_pango_layout_set_auto_dir>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_auto_dir"));
|
||
|
|
|
||
|
|
public bool AutoDir {
|
||
|
|
get {
|
||
|
|
bool raw_ret = pango_layout_get_auto_dir(Handle);
|
||
|
|
bool ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_auto_dir(Handle, value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_baseline(IntPtr raw);
|
||
|
|
static d_pango_layout_get_baseline pango_layout_get_baseline = FuncLoader.LoadFunction<d_pango_layout_get_baseline>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_baseline"));
|
||
|
|
|
||
|
|
public int Baseline {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_baseline(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_character_count(IntPtr raw);
|
||
|
|
static d_pango_layout_get_character_count pango_layout_get_character_count = FuncLoader.LoadFunction<d_pango_layout_get_character_count>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_character_count"));
|
||
|
|
|
||
|
|
public int CharacterCount {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_character_count(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_context(IntPtr raw);
|
||
|
|
static d_pango_layout_get_context pango_layout_get_context = FuncLoader.LoadFunction<d_pango_layout_get_context>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_context"));
|
||
|
|
|
||
|
|
public Pango.Context Context {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_context(Handle);
|
||
|
|
Pango.Context ret = GLib.Object.GetObject(raw_ret) as Pango.Context;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_get_cursor_pos(IntPtr raw, int index_, IntPtr strong_pos, IntPtr weak_pos);
|
||
|
|
static d_pango_layout_get_cursor_pos pango_layout_get_cursor_pos = FuncLoader.LoadFunction<d_pango_layout_get_cursor_pos>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_cursor_pos"));
|
||
|
|
|
||
|
|
public void GetCursorPos(int index_, out Pango.Rectangle strong_pos, out Pango.Rectangle weak_pos) {
|
||
|
|
IntPtr native_strong_pos = Marshal.AllocHGlobal (Marshal.SizeOf<Pango.Rectangle>());
|
||
|
|
IntPtr native_weak_pos = Marshal.AllocHGlobal (Marshal.SizeOf<Pango.Rectangle>());
|
||
|
|
pango_layout_get_cursor_pos(Handle, index_, native_strong_pos, native_weak_pos);
|
||
|
|
strong_pos = Pango.Rectangle.New (native_strong_pos);
|
||
|
|
Marshal.FreeHGlobal (native_strong_pos);
|
||
|
|
weak_pos = Pango.Rectangle.New (native_weak_pos);
|
||
|
|
Marshal.FreeHGlobal (native_weak_pos);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_ellipsize(IntPtr raw);
|
||
|
|
static d_pango_layout_get_ellipsize pango_layout_get_ellipsize = FuncLoader.LoadFunction<d_pango_layout_get_ellipsize>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_ellipsize"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_ellipsize(IntPtr raw, int ellipsize);
|
||
|
|
static d_pango_layout_set_ellipsize pango_layout_set_ellipsize = FuncLoader.LoadFunction<d_pango_layout_set_ellipsize>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_ellipsize"));
|
||
|
|
|
||
|
|
public Pango.EllipsizeMode Ellipsize {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_ellipsize(Handle);
|
||
|
|
Pango.EllipsizeMode ret = (Pango.EllipsizeMode) raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_ellipsize(Handle, (int) value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_get_extents(IntPtr raw, IntPtr ink_rect, IntPtr logical_rect);
|
||
|
|
static d_pango_layout_get_extents pango_layout_get_extents = FuncLoader.LoadFunction<d_pango_layout_get_extents>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_extents"));
|
||
|
|
|
||
|
|
public void GetExtents(out Pango.Rectangle ink_rect, out Pango.Rectangle logical_rect) {
|
||
|
|
IntPtr native_ink_rect = Marshal.AllocHGlobal (Marshal.SizeOf<Pango.Rectangle>());
|
||
|
|
IntPtr native_logical_rect = Marshal.AllocHGlobal (Marshal.SizeOf<Pango.Rectangle>());
|
||
|
|
pango_layout_get_extents(Handle, native_ink_rect, native_logical_rect);
|
||
|
|
ink_rect = Pango.Rectangle.New (native_ink_rect);
|
||
|
|
Marshal.FreeHGlobal (native_ink_rect);
|
||
|
|
logical_rect = Pango.Rectangle.New (native_logical_rect);
|
||
|
|
Marshal.FreeHGlobal (native_logical_rect);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_font_description(IntPtr raw);
|
||
|
|
static d_pango_layout_get_font_description pango_layout_get_font_description = FuncLoader.LoadFunction<d_pango_layout_get_font_description>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_font_description"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_font_description(IntPtr raw, IntPtr desc);
|
||
|
|
static d_pango_layout_set_font_description pango_layout_set_font_description = FuncLoader.LoadFunction<d_pango_layout_set_font_description>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_font_description"));
|
||
|
|
|
||
|
|
public Pango.FontDescription FontDescription {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_font_description(Handle);
|
||
|
|
Pango.FontDescription ret = raw_ret == IntPtr.Zero ? null : (Pango.FontDescription) GLib.Opaque.GetOpaque (raw_ret, typeof (Pango.FontDescription), false);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_font_description(Handle, value == null ? IntPtr.Zero : value.Handle);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_height(IntPtr raw);
|
||
|
|
static d_pango_layout_get_height pango_layout_get_height = FuncLoader.LoadFunction<d_pango_layout_get_height>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_height"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_height(IntPtr raw, int height);
|
||
|
|
static d_pango_layout_set_height pango_layout_set_height = FuncLoader.LoadFunction<d_pango_layout_set_height>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_height"));
|
||
|
|
|
||
|
|
public int Height {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_height(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_height(Handle, value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_indent(IntPtr raw);
|
||
|
|
static d_pango_layout_get_indent pango_layout_get_indent = FuncLoader.LoadFunction<d_pango_layout_get_indent>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_indent"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_indent(IntPtr raw, int indent);
|
||
|
|
static d_pango_layout_set_indent pango_layout_set_indent = FuncLoader.LoadFunction<d_pango_layout_set_indent>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_indent"));
|
||
|
|
|
||
|
|
public int Indent {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_indent(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_indent(Handle, value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_iter(IntPtr raw);
|
||
|
|
static d_pango_layout_get_iter pango_layout_get_iter = FuncLoader.LoadFunction<d_pango_layout_get_iter>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_iter"));
|
||
|
|
|
||
|
|
public Pango.LayoutIter Iter {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_iter(Handle);
|
||
|
|
Pango.LayoutIter ret = raw_ret == IntPtr.Zero ? null : (Pango.LayoutIter) GLib.Opaque.GetOpaque (raw_ret, typeof (Pango.LayoutIter), true);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate bool d_pango_layout_get_justify(IntPtr raw);
|
||
|
|
static d_pango_layout_get_justify pango_layout_get_justify = FuncLoader.LoadFunction<d_pango_layout_get_justify>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_justify"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_justify(IntPtr raw, bool justify);
|
||
|
|
static d_pango_layout_set_justify pango_layout_set_justify = FuncLoader.LoadFunction<d_pango_layout_set_justify>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_justify"));
|
||
|
|
|
||
|
|
public bool Justify {
|
||
|
|
get {
|
||
|
|
bool raw_ret = pango_layout_get_justify(Handle);
|
||
|
|
bool ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_justify(Handle, value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_line(IntPtr raw, int line);
|
||
|
|
static d_pango_layout_get_line pango_layout_get_line = FuncLoader.LoadFunction<d_pango_layout_get_line>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_line"));
|
||
|
|
|
||
|
|
public Pango.LayoutLine GetLine(int line) {
|
||
|
|
IntPtr raw_ret = pango_layout_get_line(Handle, line);
|
||
|
|
Pango.LayoutLine ret = raw_ret == IntPtr.Zero ? null : (Pango.LayoutLine) GLib.Opaque.GetOpaque (raw_ret, typeof (Pango.LayoutLine), false);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_line_count(IntPtr raw);
|
||
|
|
static d_pango_layout_get_line_count pango_layout_get_line_count = FuncLoader.LoadFunction<d_pango_layout_get_line_count>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_line_count"));
|
||
|
|
|
||
|
|
public int LineCount {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_line_count(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_line_readonly(IntPtr raw, int line);
|
||
|
|
static d_pango_layout_get_line_readonly pango_layout_get_line_readonly = FuncLoader.LoadFunction<d_pango_layout_get_line_readonly>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_line_readonly"));
|
||
|
|
|
||
|
|
public Pango.LayoutLine GetLineReadonly(int line) {
|
||
|
|
IntPtr raw_ret = pango_layout_get_line_readonly(Handle, line);
|
||
|
|
Pango.LayoutLine ret = raw_ret == IntPtr.Zero ? null : (Pango.LayoutLine) GLib.Opaque.GetOpaque (raw_ret, typeof (Pango.LayoutLine), false);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_lines_readonly(IntPtr raw);
|
||
|
|
static d_pango_layout_get_lines_readonly pango_layout_get_lines_readonly = FuncLoader.LoadFunction<d_pango_layout_get_lines_readonly>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_lines_readonly"));
|
||
|
|
|
||
|
|
public Pango.LayoutLine[] LinesReadOnly {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_lines_readonly(Handle);
|
||
|
|
Pango.LayoutLine[] ret = GLib.Marshaller.SListPtrToArray<Pango.LayoutLine, Pango.LayoutLine> (raw_ret, false, false);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_get_pixel_extents(IntPtr raw, IntPtr ink_rect, IntPtr logical_rect);
|
||
|
|
static d_pango_layout_get_pixel_extents pango_layout_get_pixel_extents = FuncLoader.LoadFunction<d_pango_layout_get_pixel_extents>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_pixel_extents"));
|
||
|
|
|
||
|
|
public void GetPixelExtents(out Pango.Rectangle ink_rect, out Pango.Rectangle logical_rect) {
|
||
|
|
IntPtr native_ink_rect = Marshal.AllocHGlobal (Marshal.SizeOf<Pango.Rectangle>());
|
||
|
|
IntPtr native_logical_rect = Marshal.AllocHGlobal (Marshal.SizeOf<Pango.Rectangle>());
|
||
|
|
pango_layout_get_pixel_extents(Handle, native_ink_rect, native_logical_rect);
|
||
|
|
ink_rect = Pango.Rectangle.New (native_ink_rect);
|
||
|
|
Marshal.FreeHGlobal (native_ink_rect);
|
||
|
|
logical_rect = Pango.Rectangle.New (native_logical_rect);
|
||
|
|
Marshal.FreeHGlobal (native_logical_rect);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_get_pixel_size(IntPtr raw, out int width, out int height);
|
||
|
|
static d_pango_layout_get_pixel_size pango_layout_get_pixel_size = FuncLoader.LoadFunction<d_pango_layout_get_pixel_size>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_pixel_size"));
|
||
|
|
|
||
|
|
public void GetPixelSize(out int width, out int height) {
|
||
|
|
pango_layout_get_pixel_size(Handle, out width, out height);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate uint d_pango_layout_get_serial(IntPtr raw);
|
||
|
|
static d_pango_layout_get_serial pango_layout_get_serial = FuncLoader.LoadFunction<d_pango_layout_get_serial>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_serial"));
|
||
|
|
|
||
|
|
public uint Serial {
|
||
|
|
get {
|
||
|
|
uint raw_ret = pango_layout_get_serial(Handle);
|
||
|
|
uint ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate bool d_pango_layout_get_single_paragraph_mode(IntPtr raw);
|
||
|
|
static d_pango_layout_get_single_paragraph_mode pango_layout_get_single_paragraph_mode = FuncLoader.LoadFunction<d_pango_layout_get_single_paragraph_mode>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_single_paragraph_mode"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_single_paragraph_mode(IntPtr raw, bool setting);
|
||
|
|
static d_pango_layout_set_single_paragraph_mode pango_layout_set_single_paragraph_mode = FuncLoader.LoadFunction<d_pango_layout_set_single_paragraph_mode>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_single_paragraph_mode"));
|
||
|
|
|
||
|
|
public bool SingleParagraphMode {
|
||
|
|
get {
|
||
|
|
bool raw_ret = pango_layout_get_single_paragraph_mode(Handle);
|
||
|
|
bool ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_single_paragraph_mode(Handle, value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_get_size(IntPtr raw, out int width, out int height);
|
||
|
|
static d_pango_layout_get_size pango_layout_get_size = FuncLoader.LoadFunction<d_pango_layout_get_size>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_size"));
|
||
|
|
|
||
|
|
public void GetSize(out int width, out int height) {
|
||
|
|
pango_layout_get_size(Handle, out width, out height);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_spacing(IntPtr raw);
|
||
|
|
static d_pango_layout_get_spacing pango_layout_get_spacing = FuncLoader.LoadFunction<d_pango_layout_get_spacing>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_spacing"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_spacing(IntPtr raw, int spacing);
|
||
|
|
static d_pango_layout_set_spacing pango_layout_set_spacing = FuncLoader.LoadFunction<d_pango_layout_set_spacing>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_spacing"));
|
||
|
|
|
||
|
|
public int Spacing {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_spacing(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_spacing(Handle, value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_tabs(IntPtr raw);
|
||
|
|
static d_pango_layout_get_tabs pango_layout_get_tabs = FuncLoader.LoadFunction<d_pango_layout_get_tabs>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_tabs"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_tabs(IntPtr raw, IntPtr tabs);
|
||
|
|
static d_pango_layout_set_tabs pango_layout_set_tabs = FuncLoader.LoadFunction<d_pango_layout_set_tabs>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_tabs"));
|
||
|
|
|
||
|
|
public Pango.TabArray Tabs {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_tabs(Handle);
|
||
|
|
Pango.TabArray ret = raw_ret == IntPtr.Zero ? null : (Pango.TabArray) GLib.Opaque.GetOpaque (raw_ret, typeof (Pango.TabArray), true);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_tabs(Handle, value == null ? IntPtr.Zero : value.Handle);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_text(IntPtr raw);
|
||
|
|
static d_pango_layout_get_text pango_layout_get_text = FuncLoader.LoadFunction<d_pango_layout_get_text>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_text"));
|
||
|
|
|
||
|
|
public string Text {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_text(Handle);
|
||
|
|
string ret = GLib.Marshaller.Utf8PtrToString (raw_ret);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate IntPtr d_pango_layout_get_type();
|
||
|
|
static d_pango_layout_get_type pango_layout_get_type = FuncLoader.LoadFunction<d_pango_layout_get_type>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_type"));
|
||
|
|
|
||
|
|
public static new GLib.GType GType {
|
||
|
|
get {
|
||
|
|
IntPtr raw_ret = pango_layout_get_type();
|
||
|
|
GLib.GType ret = new GLib.GType(raw_ret);
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_unknown_glyphs_count(IntPtr raw);
|
||
|
|
static d_pango_layout_get_unknown_glyphs_count pango_layout_get_unknown_glyphs_count = FuncLoader.LoadFunction<d_pango_layout_get_unknown_glyphs_count>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_unknown_glyphs_count"));
|
||
|
|
|
||
|
|
public int UnknownGlyphsCount {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_unknown_glyphs_count(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_width(IntPtr raw);
|
||
|
|
static d_pango_layout_get_width pango_layout_get_width = FuncLoader.LoadFunction<d_pango_layout_get_width>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_width"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_width(IntPtr raw, int width);
|
||
|
|
static d_pango_layout_set_width pango_layout_set_width = FuncLoader.LoadFunction<d_pango_layout_set_width>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_width"));
|
||
|
|
|
||
|
|
public int Width {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_width(Handle);
|
||
|
|
int ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_width(Handle, value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate int d_pango_layout_get_wrap(IntPtr raw);
|
||
|
|
static d_pango_layout_get_wrap pango_layout_get_wrap = FuncLoader.LoadFunction<d_pango_layout_get_wrap>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_get_wrap"));
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_set_wrap(IntPtr raw, int wrap);
|
||
|
|
static d_pango_layout_set_wrap pango_layout_set_wrap = FuncLoader.LoadFunction<d_pango_layout_set_wrap>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_set_wrap"));
|
||
|
|
|
||
|
|
public Pango.WrapMode Wrap {
|
||
|
|
get {
|
||
|
|
int raw_ret = pango_layout_get_wrap(Handle);
|
||
|
|
Pango.WrapMode ret = (Pango.WrapMode) raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
set {
|
||
|
|
pango_layout_set_wrap(Handle, (int) value);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_index_to_line_x(IntPtr raw, int index_, bool trailing, out int line, out int x_pos);
|
||
|
|
static d_pango_layout_index_to_line_x pango_layout_index_to_line_x = FuncLoader.LoadFunction<d_pango_layout_index_to_line_x>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_index_to_line_x"));
|
||
|
|
|
||
|
|
public void IndexToLineX(int index_, bool trailing, out int line, out int x_pos) {
|
||
|
|
pango_layout_index_to_line_x(Handle, index_, trailing, out line, out x_pos);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_index_to_pos(IntPtr raw, int index_, IntPtr pos);
|
||
|
|
static d_pango_layout_index_to_pos pango_layout_index_to_pos = FuncLoader.LoadFunction<d_pango_layout_index_to_pos>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_index_to_pos"));
|
||
|
|
|
||
|
|
public Pango.Rectangle IndexToPos(int index_) {
|
||
|
|
Pango.Rectangle pos;
|
||
|
|
IntPtr native_pos = Marshal.AllocHGlobal (Marshal.SizeOf<Pango.Rectangle>());
|
||
|
|
pango_layout_index_to_pos(Handle, index_, native_pos);
|
||
|
|
pos = Pango.Rectangle.New (native_pos);
|
||
|
|
Marshal.FreeHGlobal (native_pos);
|
||
|
|
return pos;
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate bool d_pango_layout_is_ellipsized(IntPtr raw);
|
||
|
|
static d_pango_layout_is_ellipsized pango_layout_is_ellipsized = FuncLoader.LoadFunction<d_pango_layout_is_ellipsized>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_is_ellipsized"));
|
||
|
|
|
||
|
|
public bool IsEllipsized {
|
||
|
|
get {
|
||
|
|
bool raw_ret = pango_layout_is_ellipsized(Handle);
|
||
|
|
bool ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate bool d_pango_layout_is_wrapped(IntPtr raw);
|
||
|
|
static d_pango_layout_is_wrapped pango_layout_is_wrapped = FuncLoader.LoadFunction<d_pango_layout_is_wrapped>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_is_wrapped"));
|
||
|
|
|
||
|
|
public bool IsWrapped {
|
||
|
|
get {
|
||
|
|
bool raw_ret = pango_layout_is_wrapped(Handle);
|
||
|
|
bool ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate void d_pango_layout_move_cursor_visually(IntPtr raw, bool strong, int old_index, int old_trailing, int direction, out int new_index, out int new_trailing);
|
||
|
|
static d_pango_layout_move_cursor_visually pango_layout_move_cursor_visually = FuncLoader.LoadFunction<d_pango_layout_move_cursor_visually>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_move_cursor_visually"));
|
||
|
|
|
||
|
|
public void MoveCursorVisually(bool strong, int old_index, int old_trailing, int direction, out int new_index, out int new_trailing) {
|
||
|
|
pango_layout_move_cursor_visually(Handle, strong, old_index, old_trailing, direction, out new_index, out new_trailing);
|
||
|
|
}
|
||
|
|
|
||
|
|
[UnmanagedFunctionPointer (CallingConvention.Cdecl)]
|
||
|
|
delegate bool d_pango_layout_xy_to_index(IntPtr raw, int x, int y, out int index_, out int trailing);
|
||
|
|
static d_pango_layout_xy_to_index pango_layout_xy_to_index = FuncLoader.LoadFunction<d_pango_layout_xy_to_index>(FuncLoader.GetProcAddress(GLibrary.Load(Library.Pango), "pango_layout_xy_to_index"));
|
||
|
|
|
||
|
|
public bool XyToIndex(int x, int y, out int index_, out int trailing) {
|
||
|
|
bool raw_ret = pango_layout_xy_to_index(Handle, x, y, out index_, out trailing);
|
||
|
|
bool ret = raw_ret;
|
||
|
|
return ret;
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
// Internal representation of the wrapped structure ABI.
|
||
|
|
static GLib.AbiStruct _abi_info = null;
|
||
|
|
static public unsafe new GLib.AbiStruct abi_info {
|
||
|
|
get {
|
||
|
|
if (_abi_info == null)
|
||
|
|
_abi_info = new GLib.AbiStruct (GLib.Object.abi_info.Fields);
|
||
|
|
|
||
|
|
return _abi_info;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
// End of the ABI representation.
|
||
|
|
|
||
|
|
#endregion
|
||
|
|
}
|
||
|
|
}
|