Table of Contents

Class Texture

Namespace
Gdk
Assembly
Gdk-4.0.dll
public class Texture : Object, IObject, INotifyPropertyChanged, IDisposable, Paintable, Icon, LoadableIcon, IHandle, GTypeProvider
Inheritance
Texture
Implements
Derived
Inherited Members

Constructors

Texture(bool, params ConstructArgument[])

protected Texture(bool owned, params ConstructArgument[] constructArguments)

Parameters

owned bool
constructArguments ConstructArgument[]

Texture(IntPtr, bool)

protected Texture(IntPtr ptr, bool ownedRef)

Parameters

ptr IntPtr
ownedRef bool

Fields

HeightPropertyDefinition

public static readonly Property<int, Texture> HeightPropertyDefinition

Field Value

Property<int, Texture>

WidthPropertyDefinition

public static readonly Property<int, Texture> WidthPropertyDefinition

Field Value

Property<int, Texture>

Properties

Height

public int Height { get; }

Property Value

int

Width

public int Width { get; }

Property Value

int

Methods

ComputeConcreteSize(double, double, double, double, out double, out double)

public void ComputeConcreteSize(double specifiedWidth, double specifiedHeight, double defaultWidth, double defaultHeight, out double concreteWidth, out double concreteHeight)

Parameters

specifiedWidth double
specifiedHeight double
defaultWidth double
defaultHeight double
concreteWidth double
concreteHeight double

Equal(Icon?)

public bool Equal(Icon? icon2)

Parameters

icon2 Icon

Returns

bool

GetCurrentImage()

public Paintable GetCurrentImage()

Returns

Paintable

GetFlags()

public PaintableFlags GetFlags()

Returns

PaintableFlags

GetFormat()

[Version("4.10")]
public MemoryFormat GetFormat()

Returns

MemoryFormat

GetGType()

public static Type GetGType()

Returns

Type

GetHeight()

public int GetHeight()

Returns

int

GetIntrinsicAspectRatio()

public double GetIntrinsicAspectRatio()

Returns

double

GetIntrinsicHeight()

public int GetIntrinsicHeight()

Returns

int

GetIntrinsicWidth()

public int GetIntrinsicWidth()

Returns

int

GetWidth()

public int GetWidth()

Returns

int

Hash()

public uint Hash()

Returns

uint

InvalidateContents()

public void InvalidateContents()

InvalidateSize()

public void InvalidateSize()

Load(int, out string, Cancellable?)

public InputStream Load(int size, out string type, Cancellable? cancellable)

Parameters

size int
type string
cancellable Cancellable

Returns

InputStream

LoadFinish(AsyncResult, out string)

public InputStream LoadFinish(AsyncResult res, out string type)

Parameters

res AsyncResult
type string

Returns

InputStream

NewForPixbuf(Pixbuf)

public static Texture NewForPixbuf(Pixbuf pixbuf)

Parameters

pixbuf Pixbuf

Returns

Texture

NewFromBytes(Bytes)

[Version("4.6")]
public static Texture NewFromBytes(Bytes bytes)

Parameters

bytes Bytes

Returns

Texture

NewFromFile(File)

public static Texture NewFromFile(File file)

Parameters

file File

Returns

Texture

NewFromFilename(string)

[Version("4.6")]
public static Texture NewFromFilename(string path)

Parameters

path string

Returns

Texture

NewFromResource(string)

public static Texture NewFromResource(string resourcePath)

Parameters

resourcePath string

Returns

Texture

SaveToPng(string)

public bool SaveToPng(string filename)

Parameters

filename string

Returns

bool

SaveToPngBytes()

[Version("4.6")]
public Bytes SaveToPngBytes()

Returns

Bytes

SaveToTiff(string)

[Version("4.6")]
public bool SaveToTiff(string filename)

Parameters

filename string

Returns

bool

SaveToTiffBytes()

[Version("4.6")]
public Bytes SaveToTiffBytes()

Returns

Bytes

Serialize()

[Version("2.38")]
public Variant? Serialize()

Returns

Variant

Snapshot(Snapshot, double, double)

public void Snapshot(Snapshot snapshot, double width, double height)

Parameters

snapshot Snapshot
width double
height double

ToString()

[Version("2.20")]
public string? ToString()

Returns

string