// Code generated by cmd/cgo; DO NOT EDIT. //line /home/josie/.cache/paru/clone/wiiudownloader/src/pkg/mod/github.com/gotk3/gotk3@v0.6.5-0.20240618185848-ff349ae13f56/pango/pango-types.go:1:1 /* * Copyright (c) 2015- terrak * * This file originated from: http://www.terrak.net/ * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ package pango // #include // #include "pango.go.h" // #include import _ "unsafe" import ( "unsafe" ) // LogAttr is a representation of PangoLogAttr. type LogAttr struct { pangoLogAttr * /*line :31:16*/_Ctype_PangoLogAttr /*line :31:30*/ } // Native returns a pointer to the underlying PangoLayout. func (v *LogAttr) Native() uintptr { return uintptr(unsafe.Pointer(v.native())) } func (v *LogAttr) native() * /*line :39:29*/_Ctype_PangoLogAttr /*line :39:43*/ { return (* /*line :40:11*/_Ctype_PangoLogAttr /*line :40:25*/)(unsafe.Pointer(v.pangoLogAttr)) } // EngineLang is a representation of PangoEngineLang. type EngineLang struct { pangoEngineLang * /*line :45:19*/_Ctype_PangoEngineLang /*line :45:36*/ } // Native returns a pointer to the underlying PangoLayout. func (v *EngineLang) Native() uintptr { return uintptr(unsafe.Pointer(v.native())) } func (v *EngineLang) native() * /*line :53:32*/_Ctype_PangoEngineLang /*line :53:49*/ { return (* /*line :54:11*/_Ctype_PangoEngineLang /*line :54:28*/)(unsafe.Pointer(v.pangoEngineLang)) } // EngineShape is a representation of PangoEngineShape. type EngineShape struct { pangoEngineShape * /*line :59:20*/_Ctype_PangoEngineShape /*line :59:38*/ } // Native returns a pointer to the underlying PangoLayout. func (v *EngineShape) Native() uintptr { return uintptr(unsafe.Pointer(v.native())) } func (v *EngineShape) native() * /*line :67:33*/_Ctype_PangoEngineShape /*line :67:51*/ { return (* /*line :68:11*/_Ctype_PangoEngineShape /*line :68:29*/)(unsafe.Pointer(v.pangoEngineShape)) } // Font is a representation of PangoFont. type Font struct { pangoFont * /*line :73:13*/_Ctype_PangoFont /*line :73:24*/ } // Native returns a pointer to the underlying PangoLayout. func (v *Font) Native() uintptr { return uintptr(unsafe.Pointer(v.native())) } func (v *Font) native() * /*line :81:26*/_Ctype_PangoFont /*line :81:37*/ { return (* /*line :82:11*/_Ctype_PangoFont /*line :82:22*/)(unsafe.Pointer(v.pangoFont)) } // FontMap is a representation of PangoFontMap. type FontMap struct { pangoFontMap * /*line :87:16*/_Ctype_PangoFontMap /*line :87:30*/ } // Native returns a pointer to the underlying PangoLayout. func (v *FontMap) Native() uintptr { return uintptr(unsafe.Pointer(v.native())) } func (v *FontMap) native() * /*line :95:29*/_Ctype_PangoFontMap /*line :95:43*/ { return (* /*line :96:11*/_Ctype_PangoFontMap /*line :96:25*/)(unsafe.Pointer(v.pangoFontMap)) } func wrapFontMap(fontMap * /*line :99:27*/_Ctype_PangoFontMap /*line :99:41*/) *FontMap { return &FontMap{fontMap} } func WrapFontMap(p uintptr) *FontMap { fontMap := (* /*line :104:15*/_Ctype_PangoFontMap /*line :104:29*/)(unsafe.Pointer(p)) return wrapFontMap(fontMap) } // Rectangle is a representation of PangoRectangle. type Rectangle struct { pangoRectangle * /*line :110:18*/_Ctype_PangoRectangle /*line :110:34*/ } // Native returns a pointer to the underlying PangoLayout. func (v *Rectangle) Native() uintptr { return uintptr(unsafe.Pointer(v.native())) } func (v *Rectangle) native() * /*line :118:31*/_Ctype_PangoRectangle /*line :118:47*/ { return (* /*line :119:11*/_Ctype_PangoRectangle /*line :119:27*/)(unsafe.Pointer(v.pangoRectangle)) } // Glyph is a representation of PangoGlyph type Glyph uint32 //void pango_extents_to_pixels (PangoRectangle *inclusive, // PangoRectangle *nearest); func (inclusive *Rectangle) ExtentsToPixels(nearest *Rectangle) { ( /*line :128:2*/_Cfunc_pango_extents_to_pixels /*line :128:26*/)(inclusive.native(), nearest.native()) } func RectangleNew(x, y, width, height int) *Rectangle { r := new(Rectangle) r.pangoRectangle = ( /*line :133:21*/_Cfunc_createPangoRectangle /*line :133:42*/)(( /*line :133:45*/_Ctype_int /*line :133:50*/)(x), ( /*line :133:57*/_Ctype_int /*line :133:62*/)(y), ( /*line :133:69*/_Ctype_int /*line :133:74*/)(width), ( /*line :133:85*/_Ctype_int /*line :133:90*/)(height)) return r }