Package org.gnome.pango
Class AttrFontDesc
java.lang.Object
org.javagi.base.ProxyInstance
org.gnome.pango.AttrFontDesc
- All Implemented Interfaces:
Proxy
The
PangoAttrFontDesc structure is used to store an attribute that
sets all aspects of the font description at once.-
Constructor Summary
ConstructorsConstructorDescriptionAllocate a new AttrFontDesc.AttrFontDesc(Arena arena) Allocate a new AttrFontDesc.AttrFontDesc(MemorySegment address) Create a AttrFontDesc proxy instance for the provided memory address.AttrFontDesc(Attribute attr, FontDescription desc) Allocate a new AttrFontDesc with the fields set to the provided values.AttrFontDesc(Attribute attr, FontDescription desc, Arena arena) Allocate a new AttrFontDesc with the fields set to the provided values. -
Method Summary
Modifier and TypeMethodDescriptionstatic MemoryLayoutThe memory layout of the native struct.static Attributenew_(FontDescription desc) Create a new font description attribute.@Nullable AttributereadAttr()Read the value of the fieldattr.readDesc()Read the value of the fielddesc.voidWrite a value in the fieldattr.voidwriteDesc(FontDescription desc) Write a value in the fielddesc.Methods inherited from class org.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
AttrFontDesc
Create a AttrFontDesc proxy instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
AttrFontDesc
Allocate a new AttrFontDesc.- Parameters:
arena- to control the memory allocation scope
-
AttrFontDesc
public AttrFontDesc()Allocate a new AttrFontDesc. The memory is allocated withArena.ofAuto(). -
AttrFontDesc
Allocate a new AttrFontDesc with the fields set to the provided values.- Parameters:
attr- value for the fieldattrdesc- value for the fielddescarena- to control the memory allocation scope
-
AttrFontDesc
Allocate a new AttrFontDesc with the fields set to the provided values. The memory is allocated withArena.ofAuto().- Parameters:
attr- value for the fieldattrdesc- value for the fielddesc
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readAttr
Read the value of the fieldattr.- Returns:
- The value of the field
attr
-
writeAttr
Write a value in the fieldattr.- Parameters:
attr- The new value for the fieldattr
-
readDesc
Read the value of the fielddesc.- Returns:
- The value of the field
desc
-
writeDesc
Write a value in the fielddesc.- Parameters:
desc- The new value for the fielddesc
-
new_
Create a new font description attribute.This attribute allows setting family, style, weight, variant, stretch, and size simultaneously.
- Parameters:
desc- the font description- Returns:
- the newly allocated
PangoAttribute, which should be freed withAttribute.destroy()
-