@girs/gdk-4.0 4.0.0-3.2.3 → 4.0.0-3.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/gdk-4.0.d.cts +472 -13
- package/gdk-4.0.d.ts +472 -13
- package/package.json +12 -12
package/README.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|

|
|
6
6
|
|
|
7
7
|
|
|
8
|
-
GJS TypeScript type definitions for Gdk-4.0, generated from library version 4.0.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v3.2.
|
|
8
|
+
GJS TypeScript type definitions for Gdk-4.0, generated from library version 4.0.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v3.2.4.
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
## Install
|
package/gdk-4.0.d.cts
CHANGED
|
@@ -13,12 +13,12 @@ import './gdk-4.0-import.d.ts';
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import type cairo from '@girs/cairo-1.0';
|
|
16
|
+
import type GObject from '@girs/gobject-2.0';
|
|
17
|
+
import type GLib from '@girs/glib-2.0';
|
|
16
18
|
import type PangoCairo from '@girs/pangocairo-1.0';
|
|
17
19
|
import type Pango from '@girs/pango-1.0';
|
|
18
20
|
import type HarfBuzz from '@girs/harfbuzz-0.0';
|
|
19
21
|
import type freetype2 from '@girs/freetype2-2.0';
|
|
20
|
-
import type GObject from '@girs/gobject-2.0';
|
|
21
|
-
import type GLib from '@girs/glib-2.0';
|
|
22
22
|
import type Gio from '@girs/gio-2.0';
|
|
23
23
|
import type GdkPixbuf from '@girs/gdkpixbuf-2.0';
|
|
24
24
|
import type GModule from '@girs/gmodule-2.0';
|
|
@@ -572,6 +572,46 @@ export enum MemoryFormat {
|
|
|
572
572
|
* alpha. Since: 4.6
|
|
573
573
|
*/
|
|
574
574
|
R32G32B32A32_FLOAT,
|
|
575
|
+
/**
|
|
576
|
+
* 2 bytes; for grayscale, alpha. The color
|
|
577
|
+
* values are premultiplied with the alpha value. Since: 4.12
|
|
578
|
+
*/
|
|
579
|
+
G8A8_PREMULTIPLIED,
|
|
580
|
+
/**
|
|
581
|
+
* 2 bytes; for grayscale, alpha. Since: 4.12
|
|
582
|
+
*/
|
|
583
|
+
G8A8,
|
|
584
|
+
/**
|
|
585
|
+
* One byte; for grayscale. The data is opaque.
|
|
586
|
+
* Since: 4.12
|
|
587
|
+
*/
|
|
588
|
+
G8,
|
|
589
|
+
/**
|
|
590
|
+
* 2 guint16 values; for grayscale, alpha.
|
|
591
|
+
* The color values are premultiplied with the alpha value. Since: 4.12
|
|
592
|
+
*/
|
|
593
|
+
G16A16_PREMULTIPLIED,
|
|
594
|
+
/**
|
|
595
|
+
* 2 guint16 values; for grayscale, alpha. Since: 4.12
|
|
596
|
+
*/
|
|
597
|
+
G16A16,
|
|
598
|
+
/**
|
|
599
|
+
* One guint16 value; for grayscale. The data is opaque.
|
|
600
|
+
* Since: 4.12
|
|
601
|
+
*/
|
|
602
|
+
G16,
|
|
603
|
+
/**
|
|
604
|
+
* One byte; for alpha.
|
|
605
|
+
* Since: 4.12
|
|
606
|
+
*/
|
|
607
|
+
A8,
|
|
608
|
+
/**
|
|
609
|
+
* One guint16 value; for alpha.
|
|
610
|
+
* Since: 4.12
|
|
611
|
+
*/
|
|
612
|
+
A16,
|
|
613
|
+
A16_FLOAT,
|
|
614
|
+
A32_FLOAT,
|
|
575
615
|
/**
|
|
576
616
|
* The number of formats. This value will change as
|
|
577
617
|
* more formats get added, so do not rely on its concrete integer.
|
|
@@ -1204,6 +1244,10 @@ export enum ToplevelState {
|
|
|
1204
1244
|
* whether the left edge is resizable
|
|
1205
1245
|
*/
|
|
1206
1246
|
LEFT_RESIZABLE,
|
|
1247
|
+
/**
|
|
1248
|
+
* the surface is not visible to the user
|
|
1249
|
+
*/
|
|
1250
|
+
SUSPENDED,
|
|
1207
1251
|
}
|
|
1208
1252
|
/**
|
|
1209
1253
|
* Defines all possible DND actions.
|
|
@@ -3719,6 +3763,7 @@ export function content_serialize_finish(result: Gio.AsyncResult): boolean
|
|
|
3719
3763
|
* @returns %TRUE if exactly one action was given
|
|
3720
3764
|
*/
|
|
3721
3765
|
export function drag_action_is_unique(action: DragAction): boolean
|
|
3766
|
+
export function drag_surface_size_get_type(): GObject.GType
|
|
3722
3767
|
/**
|
|
3723
3768
|
* Returns the relative angle from `event1` to `event2`.
|
|
3724
3769
|
*
|
|
@@ -4068,6 +4113,16 @@ export class DevicePad extends GObject.Object {
|
|
|
4068
4113
|
|
|
4069
4114
|
export module DragSurface {
|
|
4070
4115
|
|
|
4116
|
+
// Signal callback interfaces
|
|
4117
|
+
|
|
4118
|
+
/**
|
|
4119
|
+
* Signal callback interface for `compute-size`
|
|
4120
|
+
*/
|
|
4121
|
+
export interface ComputeSizeSignalCallback {
|
|
4122
|
+
($obj: DragSurface, size: DragSurfaceSize): void
|
|
4123
|
+
}
|
|
4124
|
+
|
|
4125
|
+
|
|
4071
4126
|
// Constructor properties interface
|
|
4072
4127
|
|
|
4073
4128
|
export interface ConstructorProperties extends Surface.ConstructorProperties, GObject.Object.ConstructorProperties {
|
|
@@ -4087,6 +4142,12 @@ export interface DragSurface extends Surface {
|
|
|
4087
4142
|
*/
|
|
4088
4143
|
present(width: number, height: number): boolean
|
|
4089
4144
|
|
|
4145
|
+
// Own signals of Gdk-4.0.Gdk.DragSurface
|
|
4146
|
+
|
|
4147
|
+
connect(sigName: "compute-size", callback: DragSurface.ComputeSizeSignalCallback): number
|
|
4148
|
+
connect_after(sigName: "compute-size", callback: DragSurface.ComputeSizeSignalCallback): number
|
|
4149
|
+
emit(sigName: "compute-size", size: DragSurfaceSize, ...args: any[]): void
|
|
4150
|
+
|
|
4090
4151
|
// Class property signals of Gdk-4.0.Gdk.DragSurface
|
|
4091
4152
|
|
|
4092
4153
|
connect(sigName: "notify::cursor", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
@@ -4104,6 +4165,9 @@ export interface DragSurface extends Surface {
|
|
|
4104
4165
|
connect(sigName: "notify::mapped", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4105
4166
|
connect_after(sigName: "notify::mapped", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4106
4167
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
4168
|
+
connect(sigName: "notify::scale", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4169
|
+
connect_after(sigName: "notify::scale", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4170
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
4107
4171
|
connect(sigName: "notify::scale-factor", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4108
4172
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4109
4173
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -4581,6 +4645,9 @@ export interface Popup extends Surface {
|
|
|
4581
4645
|
connect(sigName: "notify::mapped", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4582
4646
|
connect_after(sigName: "notify::mapped", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4583
4647
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
4648
|
+
connect(sigName: "notify::scale", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4649
|
+
connect_after(sigName: "notify::scale", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4650
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
4584
4651
|
connect(sigName: "notify::scale-factor", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4585
4652
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4586
4653
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -4966,6 +5033,9 @@ export interface Toplevel extends Surface {
|
|
|
4966
5033
|
connect(sigName: "notify::mapped", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4967
5034
|
connect_after(sigName: "notify::mapped", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4968
5035
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
5036
|
+
connect(sigName: "notify::scale", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
5037
|
+
connect_after(sigName: "notify::scale", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
5038
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
4969
5039
|
connect(sigName: "notify::scale-factor", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4970
5040
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4971
5041
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -7173,8 +7243,7 @@ export interface Display {
|
|
|
7173
7243
|
*/
|
|
7174
7244
|
prepare_gl(): boolean
|
|
7175
7245
|
/**
|
|
7176
|
-
*
|
|
7177
|
-
* queue for `display`.
|
|
7246
|
+
* Adds the given event to the event queue for `display`.
|
|
7178
7247
|
* @param event a `GdkEvent`
|
|
7179
7248
|
*/
|
|
7180
7249
|
put_event(event: Event): void
|
|
@@ -8252,6 +8321,8 @@ export interface Event {
|
|
|
8252
8321
|
get_pointer_emulated(): boolean
|
|
8253
8322
|
/**
|
|
8254
8323
|
* Extract the event surface relative x/y coordinates from an event.
|
|
8324
|
+
*
|
|
8325
|
+
* This position is in [surface coordinates](coordinates.html).
|
|
8255
8326
|
*/
|
|
8256
8327
|
get_position(): [ /* returnType */ boolean, /* x */ number, /* y */ number ]
|
|
8257
8328
|
/**
|
|
@@ -8682,9 +8753,6 @@ export interface GLContext {
|
|
|
8682
8753
|
* Retrieves the OpenGL version of the `context`.
|
|
8683
8754
|
*
|
|
8684
8755
|
* The `context` must be realized prior to calling this function.
|
|
8685
|
-
*
|
|
8686
|
-
* If the `context` has never been made current, the version cannot
|
|
8687
|
-
* be known and it will return 0 for both `major` and `minor`.
|
|
8688
8756
|
*/
|
|
8689
8757
|
get_version(): [ /* major */ number, /* minor */ number ]
|
|
8690
8758
|
/**
|
|
@@ -8987,6 +9055,337 @@ export class GLTexture extends Texture {
|
|
|
8987
9055
|
_init(config?: GLTexture.ConstructorProperties): void
|
|
8988
9056
|
}
|
|
8989
9057
|
|
|
9058
|
+
export module GLTextureBuilder {
|
|
9059
|
+
|
|
9060
|
+
// Constructor properties interface
|
|
9061
|
+
|
|
9062
|
+
export interface ConstructorProperties extends GObject.Object.ConstructorProperties {
|
|
9063
|
+
|
|
9064
|
+
// Own constructor properties of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9065
|
+
|
|
9066
|
+
/**
|
|
9067
|
+
* The context owning the texture.
|
|
9068
|
+
*/
|
|
9069
|
+
context?: GLContext | null
|
|
9070
|
+
/**
|
|
9071
|
+
* The format when downloading the texture.
|
|
9072
|
+
*/
|
|
9073
|
+
format?: MemoryFormat | null
|
|
9074
|
+
/**
|
|
9075
|
+
* If the texture has a mipmap.
|
|
9076
|
+
*/
|
|
9077
|
+
has_mipmap?: boolean | null
|
|
9078
|
+
/**
|
|
9079
|
+
* The height of the texture.
|
|
9080
|
+
*/
|
|
9081
|
+
height?: number | null
|
|
9082
|
+
/**
|
|
9083
|
+
* The texture ID to use.
|
|
9084
|
+
*/
|
|
9085
|
+
id?: number | null
|
|
9086
|
+
/**
|
|
9087
|
+
* An optional `GLSync` object.
|
|
9088
|
+
*
|
|
9089
|
+
* If this is set, GTK will wait on it before using the texture.
|
|
9090
|
+
*/
|
|
9091
|
+
sync?: any | null
|
|
9092
|
+
/**
|
|
9093
|
+
* The update region for [property`Gdk`.GLTextureBuilder:update-texture].
|
|
9094
|
+
*/
|
|
9095
|
+
update_region?: cairo.Region | null
|
|
9096
|
+
/**
|
|
9097
|
+
* The texture [property`Gdk`.GLTextureBuilder:update-region] is an update for.
|
|
9098
|
+
*/
|
|
9099
|
+
update_texture?: Texture | null
|
|
9100
|
+
/**
|
|
9101
|
+
* The width of the texture.
|
|
9102
|
+
*/
|
|
9103
|
+
width?: number | null
|
|
9104
|
+
}
|
|
9105
|
+
|
|
9106
|
+
}
|
|
9107
|
+
|
|
9108
|
+
export interface GLTextureBuilder {
|
|
9109
|
+
|
|
9110
|
+
// Own properties of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9111
|
+
|
|
9112
|
+
/**
|
|
9113
|
+
* The context owning the texture.
|
|
9114
|
+
*/
|
|
9115
|
+
context: GLContext
|
|
9116
|
+
/**
|
|
9117
|
+
* The format when downloading the texture.
|
|
9118
|
+
*/
|
|
9119
|
+
format: MemoryFormat
|
|
9120
|
+
/**
|
|
9121
|
+
* If the texture has a mipmap.
|
|
9122
|
+
*/
|
|
9123
|
+
has_mipmap: boolean
|
|
9124
|
+
/**
|
|
9125
|
+
* The height of the texture.
|
|
9126
|
+
*/
|
|
9127
|
+
height: number
|
|
9128
|
+
/**
|
|
9129
|
+
* The texture ID to use.
|
|
9130
|
+
*/
|
|
9131
|
+
id: number
|
|
9132
|
+
/**
|
|
9133
|
+
* An optional `GLSync` object.
|
|
9134
|
+
*
|
|
9135
|
+
* If this is set, GTK will wait on it before using the texture.
|
|
9136
|
+
*/
|
|
9137
|
+
sync: any
|
|
9138
|
+
/**
|
|
9139
|
+
* The update region for [property`Gdk`.GLTextureBuilder:update-texture].
|
|
9140
|
+
*/
|
|
9141
|
+
update_region: cairo.Region
|
|
9142
|
+
/**
|
|
9143
|
+
* The texture [property`Gdk`.GLTextureBuilder:update-region] is an update for.
|
|
9144
|
+
*/
|
|
9145
|
+
update_texture: Texture
|
|
9146
|
+
/**
|
|
9147
|
+
* The width of the texture.
|
|
9148
|
+
*/
|
|
9149
|
+
width: number
|
|
9150
|
+
|
|
9151
|
+
// Owm methods of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9152
|
+
|
|
9153
|
+
/**
|
|
9154
|
+
* Builds a new `GdkTexture` with the values set up in the builder.
|
|
9155
|
+
*
|
|
9156
|
+
* The `destroy` function gets called when the returned texture gets released;
|
|
9157
|
+
* either when the texture is finalized or by an explicit call to
|
|
9158
|
+
* [method`Gdk`.GLTexture.release]. It should release all GL resources associated
|
|
9159
|
+
* with the texture, such as the [property`Gdk`.GLTextureBuilder:id] and the
|
|
9160
|
+
* [property`Gdk`.GLTextureBuilder:sync].
|
|
9161
|
+
*
|
|
9162
|
+
* Note that it is a programming error to call this function if any mandatory
|
|
9163
|
+
* property has not been set.
|
|
9164
|
+
*
|
|
9165
|
+
* It is possible to call this function multiple times to create multiple textures,
|
|
9166
|
+
* possibly with changing properties in between.
|
|
9167
|
+
* @param destroy destroy function to be called when the texture is released
|
|
9168
|
+
* @param data user data to pass to the destroy function
|
|
9169
|
+
* @returns a newly built `GdkTexture`
|
|
9170
|
+
*/
|
|
9171
|
+
build(destroy: GLib.DestroyNotify | null, data: any | null): Texture
|
|
9172
|
+
/**
|
|
9173
|
+
* Gets the context previously set via gdk_gl_texture_builder_set_context() or
|
|
9174
|
+
* %NULL if none was set.
|
|
9175
|
+
* @returns The context
|
|
9176
|
+
*/
|
|
9177
|
+
get_context(): GLContext | null
|
|
9178
|
+
/**
|
|
9179
|
+
* Gets the format previously set via gdk_gl_texture_builder_set_format().
|
|
9180
|
+
* @returns The format
|
|
9181
|
+
*/
|
|
9182
|
+
get_format(): MemoryFormat
|
|
9183
|
+
/**
|
|
9184
|
+
* Gets whether the texture has a mipmap.
|
|
9185
|
+
* @returns Whether the texture has a mipmap
|
|
9186
|
+
*/
|
|
9187
|
+
get_has_mipmap(): boolean
|
|
9188
|
+
/**
|
|
9189
|
+
* Gets the height previously set via gdk_gl_texture_builder_set_height() or
|
|
9190
|
+
* 0 if the height wasn't set.
|
|
9191
|
+
* @returns The height
|
|
9192
|
+
*/
|
|
9193
|
+
get_height(): number
|
|
9194
|
+
/**
|
|
9195
|
+
* Gets the texture id previously set via gdk_gl_texture_builder_set_id() or
|
|
9196
|
+
* 0 if the id wasn't set.
|
|
9197
|
+
* @returns The id
|
|
9198
|
+
*/
|
|
9199
|
+
get_id(): number
|
|
9200
|
+
/**
|
|
9201
|
+
* Gets the `GLsync` previously set via gdk_gl_texture_builder_set_sync().
|
|
9202
|
+
* @returns the `GLSync`
|
|
9203
|
+
*/
|
|
9204
|
+
get_sync(): any | null
|
|
9205
|
+
/**
|
|
9206
|
+
* Gets the region previously set via gdk_gl_texture_builder_set_update_region() or
|
|
9207
|
+
* %NULL if none was set.
|
|
9208
|
+
* @returns The region
|
|
9209
|
+
*/
|
|
9210
|
+
get_update_region(): cairo.Region | null
|
|
9211
|
+
/**
|
|
9212
|
+
* Gets the texture previously set via gdk_gl_texture_builder_set_update_texture() or
|
|
9213
|
+
* %NULL if none was set.
|
|
9214
|
+
* @returns The texture
|
|
9215
|
+
*/
|
|
9216
|
+
get_update_texture(): Texture | null
|
|
9217
|
+
/**
|
|
9218
|
+
* Gets the width previously set via gdk_gl_texture_builder_set_width() or
|
|
9219
|
+
* 0 if the width wasn't set.
|
|
9220
|
+
* @returns The width
|
|
9221
|
+
*/
|
|
9222
|
+
get_width(): number
|
|
9223
|
+
/**
|
|
9224
|
+
* Sets the context to be used for the texture. This is the context that owns
|
|
9225
|
+
* the texture.
|
|
9226
|
+
*
|
|
9227
|
+
* The context must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9228
|
+
* @param context The context the texture beongs to or %NULL to unset
|
|
9229
|
+
*/
|
|
9230
|
+
set_context(context: GLContext | null): void
|
|
9231
|
+
/**
|
|
9232
|
+
* Sets the format of the texture. The default is `GDK_MEMORY_R8G8B8A8_PREMULTIPLIED`.
|
|
9233
|
+
*
|
|
9234
|
+
* The format is the preferred format the texture data should be downloaded to. The
|
|
9235
|
+
* format must be supported by the GL version of [property`Gdk`.GLTextureBuilder:context].
|
|
9236
|
+
*
|
|
9237
|
+
* GDK's texture download code assumes that the format corresponds to the storage
|
|
9238
|
+
* parameters of the GL texture in an obvious way. For example, a format of
|
|
9239
|
+
* `GDK_MEMORY_R16G16B16A16_PREMULTIPLIED` is expected to be stored as `GL_RGBA16`
|
|
9240
|
+
* texture, and `GDK_MEMORY_G8A8` is expected to be stored as `GL_RG8` texture.
|
|
9241
|
+
*
|
|
9242
|
+
* Setting the right format is particularly useful when using high bit depth textures
|
|
9243
|
+
* to preserve the bit depth, to set the correct value for unpremultiplied textures
|
|
9244
|
+
* and to make sure opaque textures are treated as such.
|
|
9245
|
+
*
|
|
9246
|
+
* Non-RGBA textures need to have swizzling parameters set up properly to be usable
|
|
9247
|
+
* in GSK's shaders.
|
|
9248
|
+
* @param format The texture's format
|
|
9249
|
+
*/
|
|
9250
|
+
set_format(format: MemoryFormat): void
|
|
9251
|
+
/**
|
|
9252
|
+
* Sets whether the texture has a mipmap. This allows the renderer and other users of the
|
|
9253
|
+
* generated texture to use a higher quality downscaling.
|
|
9254
|
+
*
|
|
9255
|
+
* Typically, the `glGenerateMipmap` function is used to generate a mimap.
|
|
9256
|
+
* @param has_mipmap Whether the texture has a mipmap
|
|
9257
|
+
*/
|
|
9258
|
+
set_has_mipmap(has_mipmap: boolean): void
|
|
9259
|
+
/**
|
|
9260
|
+
* Sets the height of the texture.
|
|
9261
|
+
*
|
|
9262
|
+
* The height must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9263
|
+
* @param height The texture's height or 0 to unset
|
|
9264
|
+
*/
|
|
9265
|
+
set_height(height: number): void
|
|
9266
|
+
/**
|
|
9267
|
+
* Sets the texture id of the texture. The texture id must remain unmodified
|
|
9268
|
+
* until the texture was finalized. See [method`Gdk`.GLTextureBuilder.build]
|
|
9269
|
+
* for a longer discussion.
|
|
9270
|
+
*
|
|
9271
|
+
* The id must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9272
|
+
* @param id The texture id to be used for creating the texture
|
|
9273
|
+
*/
|
|
9274
|
+
set_id(id: number): void
|
|
9275
|
+
/**
|
|
9276
|
+
* Sets the GLSync object to use for the texture.
|
|
9277
|
+
*
|
|
9278
|
+
* GTK will wait on this object before using the created `GdkTexture`.
|
|
9279
|
+
*
|
|
9280
|
+
* The `destroy` function that is passed to [method`Gdk`.GLTextureBuilder.build]
|
|
9281
|
+
* is responsible for freeing the sync object when it is no longer needed.
|
|
9282
|
+
* The texture builder does not destroy it and it is the callers
|
|
9283
|
+
* responsibility to make sure it doesn't leak.
|
|
9284
|
+
* @param sync the GLSync object
|
|
9285
|
+
*/
|
|
9286
|
+
set_sync(sync: any | null): void
|
|
9287
|
+
/**
|
|
9288
|
+
* Sets the region to be updated by this texture. Together with
|
|
9289
|
+
* [property`Gdk`.GLTextureBuilder:update-texture] this describes an
|
|
9290
|
+
* update of a previous texture.
|
|
9291
|
+
*
|
|
9292
|
+
* When rendering animations of large textures, it is possible that
|
|
9293
|
+
* consecutive textures are only updating contents in parts of the texture.
|
|
9294
|
+
* It is then possible to describe this update via these two properties,
|
|
9295
|
+
* so that GTK can avoid rerendering parts that did not change.
|
|
9296
|
+
*
|
|
9297
|
+
* An example would be a screen recording where only the mouse pointer moves.
|
|
9298
|
+
* @param region the region to update
|
|
9299
|
+
*/
|
|
9300
|
+
set_update_region(region: cairo.Region | null): void
|
|
9301
|
+
/**
|
|
9302
|
+
* Sets the texture to be updated by this texture. See
|
|
9303
|
+
* [method`Gdk`.GLTextureBuilder.set_update_region] for an explanation.
|
|
9304
|
+
* @param texture the texture to update
|
|
9305
|
+
*/
|
|
9306
|
+
set_update_texture(texture: Texture | null): void
|
|
9307
|
+
/**
|
|
9308
|
+
* Sets the width of the texture.
|
|
9309
|
+
*
|
|
9310
|
+
* The width must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9311
|
+
* @param width The texture's width or 0 to unset
|
|
9312
|
+
*/
|
|
9313
|
+
set_width(width: number): void
|
|
9314
|
+
|
|
9315
|
+
// Class property signals of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9316
|
+
|
|
9317
|
+
connect(sigName: "notify::context", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9318
|
+
connect_after(sigName: "notify::context", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9319
|
+
emit(sigName: "notify::context", ...args: any[]): void
|
|
9320
|
+
connect(sigName: "notify::format", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9321
|
+
connect_after(sigName: "notify::format", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9322
|
+
emit(sigName: "notify::format", ...args: any[]): void
|
|
9323
|
+
connect(sigName: "notify::has-mipmap", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9324
|
+
connect_after(sigName: "notify::has-mipmap", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9325
|
+
emit(sigName: "notify::has-mipmap", ...args: any[]): void
|
|
9326
|
+
connect(sigName: "notify::height", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9327
|
+
connect_after(sigName: "notify::height", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9328
|
+
emit(sigName: "notify::height", ...args: any[]): void
|
|
9329
|
+
connect(sigName: "notify::id", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9330
|
+
connect_after(sigName: "notify::id", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9331
|
+
emit(sigName: "notify::id", ...args: any[]): void
|
|
9332
|
+
connect(sigName: "notify::sync", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9333
|
+
connect_after(sigName: "notify::sync", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9334
|
+
emit(sigName: "notify::sync", ...args: any[]): void
|
|
9335
|
+
connect(sigName: "notify::update-region", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9336
|
+
connect_after(sigName: "notify::update-region", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9337
|
+
emit(sigName: "notify::update-region", ...args: any[]): void
|
|
9338
|
+
connect(sigName: "notify::update-texture", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9339
|
+
connect_after(sigName: "notify::update-texture", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9340
|
+
emit(sigName: "notify::update-texture", ...args: any[]): void
|
|
9341
|
+
connect(sigName: "notify::width", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9342
|
+
connect_after(sigName: "notify::width", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9343
|
+
emit(sigName: "notify::width", ...args: any[]): void
|
|
9344
|
+
connect(sigName: string, callback: (...args: any[]) => void): number
|
|
9345
|
+
connect_after(sigName: string, callback: (...args: any[]) => void): number
|
|
9346
|
+
emit(sigName: string, ...args: any[]): void
|
|
9347
|
+
disconnect(id: number): void
|
|
9348
|
+
}
|
|
9349
|
+
|
|
9350
|
+
/**
|
|
9351
|
+
* `GdkGLTextureBuilder` is a buider used to construct [class`Gdk`.Texture] objects from
|
|
9352
|
+
* GL textures.
|
|
9353
|
+
*
|
|
9354
|
+
* The operation is quite simple: Create a texture builder, set all the necessary
|
|
9355
|
+
* properties - keep in mind that the properties [property`Gdk`.GLTextureBuilder:context],
|
|
9356
|
+
* [property`Gdk`.GLTextureBuilder:id], [property`Gdk`.GLTextureBuilder:width], and
|
|
9357
|
+
* [property`Gdk`.GLTextureBuilder:height] are mandatory - and then call
|
|
9358
|
+
* [method`Gdk`.GLTextureBuilder.build] to create the new texture.
|
|
9359
|
+
*
|
|
9360
|
+
* `GdkGLTextureBuilder` can be used for quick one-shot construction of
|
|
9361
|
+
* textures as well as kept around and reused to construct multiple textures.
|
|
9362
|
+
* @class
|
|
9363
|
+
*/
|
|
9364
|
+
export class GLTextureBuilder extends GObject.Object {
|
|
9365
|
+
|
|
9366
|
+
// Own properties of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9367
|
+
|
|
9368
|
+
static name: string
|
|
9369
|
+
static $gtype: GObject.GType<GLTextureBuilder>
|
|
9370
|
+
|
|
9371
|
+
// Constructors of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9372
|
+
|
|
9373
|
+
constructor(config?: GLTextureBuilder.ConstructorProperties)
|
|
9374
|
+
/**
|
|
9375
|
+
* Creates a new texture builder.
|
|
9376
|
+
* @constructor
|
|
9377
|
+
* @returns the new `GdkTextureBuilder`
|
|
9378
|
+
*/
|
|
9379
|
+
constructor()
|
|
9380
|
+
/**
|
|
9381
|
+
* Creates a new texture builder.
|
|
9382
|
+
* @constructor
|
|
9383
|
+
* @returns the new `GdkTextureBuilder`
|
|
9384
|
+
*/
|
|
9385
|
+
static new(): GLTextureBuilder
|
|
9386
|
+
_init(config?: GLTextureBuilder.ConstructorProperties): void
|
|
9387
|
+
}
|
|
9388
|
+
|
|
8990
9389
|
export interface GrabBrokenEvent {
|
|
8991
9390
|
|
|
8992
9391
|
// Owm methods of Gdk-4.0.Gdk.GrabBrokenEvent
|
|
@@ -9773,8 +10172,15 @@ export interface Surface {
|
|
|
9773
10172
|
* Whether the surface is mapped.
|
|
9774
10173
|
*/
|
|
9775
10174
|
readonly mapped: boolean
|
|
10175
|
+
/**
|
|
10176
|
+
* The scale of the surface.
|
|
10177
|
+
*/
|
|
10178
|
+
readonly scale: number
|
|
9776
10179
|
/**
|
|
9777
10180
|
* The scale factor of the surface.
|
|
10181
|
+
*
|
|
10182
|
+
* The scale factor is the next larger integer,
|
|
10183
|
+
* compared to [property`Gdk`.Surface:scale].
|
|
9778
10184
|
*/
|
|
9779
10185
|
readonly scale_factor: number
|
|
9780
10186
|
/**
|
|
@@ -9908,6 +10314,21 @@ export interface Surface {
|
|
|
9908
10314
|
* @returns %TRUE if the surface is mapped
|
|
9909
10315
|
*/
|
|
9910
10316
|
get_mapped(): boolean
|
|
10317
|
+
/**
|
|
10318
|
+
* Returns the internal scale that maps from surface coordinates
|
|
10319
|
+
* to the actual device pixels.
|
|
10320
|
+
*
|
|
10321
|
+
* When the scale is bigger than 1, the windowing system prefers to get
|
|
10322
|
+
* buffers with a resolution that is bigger than the surface size (e.g.
|
|
10323
|
+
* to show the surface on a high-resolution display, or in a magnifier).
|
|
10324
|
+
*
|
|
10325
|
+
* Compare with [method`Gdk`.Surface.get_scale_factor], which returns the
|
|
10326
|
+
* next larger integer.
|
|
10327
|
+
*
|
|
10328
|
+
* The scale may change during the lifetime of the surface.
|
|
10329
|
+
* @returns the scale
|
|
10330
|
+
*/
|
|
10331
|
+
get_scale(): number
|
|
9911
10332
|
/**
|
|
9912
10333
|
* Returns the internal scale factor that maps from surface coordinates
|
|
9913
10334
|
* to the actual device pixels.
|
|
@@ -9919,7 +10340,7 @@ export interface Surface {
|
|
|
9919
10340
|
* pixel-based data the scale value can be used to determine whether to
|
|
9920
10341
|
* use a pixel resource with higher resolution data.
|
|
9921
10342
|
*
|
|
9922
|
-
* The scale
|
|
10343
|
+
* The scale factor may change during the lifetime of the surface.
|
|
9923
10344
|
* @returns the scale factor
|
|
9924
10345
|
*/
|
|
9925
10346
|
get_scale_factor(): number
|
|
@@ -10067,6 +10488,9 @@ export interface Surface {
|
|
|
10067
10488
|
connect(sigName: "notify::mapped", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10068
10489
|
connect_after(sigName: "notify::mapped", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10069
10490
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
10491
|
+
connect(sigName: "notify::scale", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10492
|
+
connect_after(sigName: "notify::scale", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10493
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
10070
10494
|
connect(sigName: "notify::scale-factor", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10071
10495
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10072
10496
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -10283,7 +10707,8 @@ export interface Texture extends Paintable, Gio.Icon, Gio.LoadableIcon {
|
|
|
10283
10707
|
* multiple frames, and will be used for a long time.
|
|
10284
10708
|
*
|
|
10285
10709
|
* There are various ways to create `GdkTexture` objects from a
|
|
10286
|
-
* [class`GdkPixbuf`.Pixbuf], or
|
|
10710
|
+
* [class`GdkPixbuf`.Pixbuf], or from bytes stored in memory, a file, or a
|
|
10711
|
+
* [struct`Gio`.Resource].
|
|
10287
10712
|
*
|
|
10288
10713
|
* The ownership of the pixel data is transferred to the `GdkTexture`
|
|
10289
10714
|
* instance; you can only make a copy of it, via [method`Gdk`.Texture.download].
|
|
@@ -10851,6 +11276,30 @@ export abstract class DragSurfaceInterface {
|
|
|
10851
11276
|
static name: string
|
|
10852
11277
|
}
|
|
10853
11278
|
|
|
11279
|
+
export interface DragSurfaceSize {
|
|
11280
|
+
|
|
11281
|
+
// Owm methods of Gdk-4.0.Gdk.DragSurfaceSize
|
|
11282
|
+
|
|
11283
|
+
/**
|
|
11284
|
+
* Sets the size the drag surface prefers to be resized to.
|
|
11285
|
+
* @param width the width
|
|
11286
|
+
* @param height the height
|
|
11287
|
+
*/
|
|
11288
|
+
set_size(width: number, height: number): void
|
|
11289
|
+
}
|
|
11290
|
+
|
|
11291
|
+
/**
|
|
11292
|
+
* The `GdkDragSurfaceSize` struct contains information that is useful
|
|
11293
|
+
* to compute the size of a drag surface.
|
|
11294
|
+
* @record
|
|
11295
|
+
*/
|
|
11296
|
+
export class DragSurfaceSize {
|
|
11297
|
+
|
|
11298
|
+
// Own properties of Gdk-4.0.Gdk.DragSurfaceSize
|
|
11299
|
+
|
|
11300
|
+
static name: string
|
|
11301
|
+
}
|
|
11302
|
+
|
|
10854
11303
|
export interface EventSequence {
|
|
10855
11304
|
}
|
|
10856
11305
|
|
|
@@ -11030,6 +11479,16 @@ export class FrameTimings {
|
|
|
11030
11479
|
static name: string
|
|
11031
11480
|
}
|
|
11032
11481
|
|
|
11482
|
+
export interface GLTextureBuilderClass {
|
|
11483
|
+
}
|
|
11484
|
+
|
|
11485
|
+
export abstract class GLTextureBuilderClass {
|
|
11486
|
+
|
|
11487
|
+
// Own properties of Gdk-4.0.Gdk.GLTextureBuilderClass
|
|
11488
|
+
|
|
11489
|
+
static name: string
|
|
11490
|
+
}
|
|
11491
|
+
|
|
11033
11492
|
export interface GLTextureClass {
|
|
11034
11493
|
}
|
|
11035
11494
|
|
|
@@ -11592,10 +12051,10 @@ export interface TextureDownloader {
|
|
|
11592
12051
|
* be stored in the stride value.
|
|
11593
12052
|
*
|
|
11594
12053
|
* This function will abort if it tries to download a large texture and
|
|
11595
|
-
* fails to allocate memory. If you think that may happen, you should
|
|
11596
|
-
*
|
|
11597
|
-
*
|
|
11598
|
-
* @returns The downloaded pixels
|
|
12054
|
+
* fails to allocate memory. If you think that may happen, you should handle
|
|
12055
|
+
* memory allocation yourself and use [method`Gdk`.TextureDownloader.download_into]
|
|
12056
|
+
* once allocation succeeded.
|
|
12057
|
+
* @returns The downloaded pixels
|
|
11599
12058
|
*/
|
|
11600
12059
|
download_bytes(): [ /* returnType */ GLib.Bytes, /* out_stride */ number ]
|
|
11601
12060
|
/**
|
package/gdk-4.0.d.ts
CHANGED
|
@@ -13,12 +13,12 @@ import './gdk-4.0-import.d.ts';
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import type cairo from '@girs/cairo-1.0';
|
|
16
|
+
import type GObject from '@girs/gobject-2.0';
|
|
17
|
+
import type GLib from '@girs/glib-2.0';
|
|
16
18
|
import type PangoCairo from '@girs/pangocairo-1.0';
|
|
17
19
|
import type Pango from '@girs/pango-1.0';
|
|
18
20
|
import type HarfBuzz from '@girs/harfbuzz-0.0';
|
|
19
21
|
import type freetype2 from '@girs/freetype2-2.0';
|
|
20
|
-
import type GObject from '@girs/gobject-2.0';
|
|
21
|
-
import type GLib from '@girs/glib-2.0';
|
|
22
22
|
import type Gio from '@girs/gio-2.0';
|
|
23
23
|
import type GdkPixbuf from '@girs/gdkpixbuf-2.0';
|
|
24
24
|
import type GModule from '@girs/gmodule-2.0';
|
|
@@ -574,6 +574,46 @@ enum MemoryFormat {
|
|
|
574
574
|
* alpha. Since: 4.6
|
|
575
575
|
*/
|
|
576
576
|
R32G32B32A32_FLOAT,
|
|
577
|
+
/**
|
|
578
|
+
* 2 bytes; for grayscale, alpha. The color
|
|
579
|
+
* values are premultiplied with the alpha value. Since: 4.12
|
|
580
|
+
*/
|
|
581
|
+
G8A8_PREMULTIPLIED,
|
|
582
|
+
/**
|
|
583
|
+
* 2 bytes; for grayscale, alpha. Since: 4.12
|
|
584
|
+
*/
|
|
585
|
+
G8A8,
|
|
586
|
+
/**
|
|
587
|
+
* One byte; for grayscale. The data is opaque.
|
|
588
|
+
* Since: 4.12
|
|
589
|
+
*/
|
|
590
|
+
G8,
|
|
591
|
+
/**
|
|
592
|
+
* 2 guint16 values; for grayscale, alpha.
|
|
593
|
+
* The color values are premultiplied with the alpha value. Since: 4.12
|
|
594
|
+
*/
|
|
595
|
+
G16A16_PREMULTIPLIED,
|
|
596
|
+
/**
|
|
597
|
+
* 2 guint16 values; for grayscale, alpha. Since: 4.12
|
|
598
|
+
*/
|
|
599
|
+
G16A16,
|
|
600
|
+
/**
|
|
601
|
+
* One guint16 value; for grayscale. The data is opaque.
|
|
602
|
+
* Since: 4.12
|
|
603
|
+
*/
|
|
604
|
+
G16,
|
|
605
|
+
/**
|
|
606
|
+
* One byte; for alpha.
|
|
607
|
+
* Since: 4.12
|
|
608
|
+
*/
|
|
609
|
+
A8,
|
|
610
|
+
/**
|
|
611
|
+
* One guint16 value; for alpha.
|
|
612
|
+
* Since: 4.12
|
|
613
|
+
*/
|
|
614
|
+
A16,
|
|
615
|
+
A16_FLOAT,
|
|
616
|
+
A32_FLOAT,
|
|
577
617
|
/**
|
|
578
618
|
* The number of formats. This value will change as
|
|
579
619
|
* more formats get added, so do not rely on its concrete integer.
|
|
@@ -1206,6 +1246,10 @@ enum ToplevelState {
|
|
|
1206
1246
|
* whether the left edge is resizable
|
|
1207
1247
|
*/
|
|
1208
1248
|
LEFT_RESIZABLE,
|
|
1249
|
+
/**
|
|
1250
|
+
* the surface is not visible to the user
|
|
1251
|
+
*/
|
|
1252
|
+
SUSPENDED,
|
|
1209
1253
|
}
|
|
1210
1254
|
/**
|
|
1211
1255
|
* Defines all possible DND actions.
|
|
@@ -3721,6 +3765,7 @@ function content_serialize_finish(result: Gio.AsyncResult): boolean
|
|
|
3721
3765
|
* @returns %TRUE if exactly one action was given
|
|
3722
3766
|
*/
|
|
3723
3767
|
function drag_action_is_unique(action: DragAction): boolean
|
|
3768
|
+
function drag_surface_size_get_type(): GObject.GType
|
|
3724
3769
|
/**
|
|
3725
3770
|
* Returns the relative angle from `event1` to `event2`.
|
|
3726
3771
|
*
|
|
@@ -4070,6 +4115,16 @@ class DevicePad extends GObject.Object {
|
|
|
4070
4115
|
|
|
4071
4116
|
module DragSurface {
|
|
4072
4117
|
|
|
4118
|
+
// Signal callback interfaces
|
|
4119
|
+
|
|
4120
|
+
/**
|
|
4121
|
+
* Signal callback interface for `compute-size`
|
|
4122
|
+
*/
|
|
4123
|
+
interface ComputeSizeSignalCallback {
|
|
4124
|
+
($obj: DragSurface, size: DragSurfaceSize): void
|
|
4125
|
+
}
|
|
4126
|
+
|
|
4127
|
+
|
|
4073
4128
|
// Constructor properties interface
|
|
4074
4129
|
|
|
4075
4130
|
interface ConstructorProperties extends Surface.ConstructorProperties, GObject.Object.ConstructorProperties {
|
|
@@ -4089,6 +4144,12 @@ interface DragSurface extends Surface {
|
|
|
4089
4144
|
*/
|
|
4090
4145
|
present(width: number, height: number): boolean
|
|
4091
4146
|
|
|
4147
|
+
// Own signals of Gdk-4.0.Gdk.DragSurface
|
|
4148
|
+
|
|
4149
|
+
connect(sigName: "compute-size", callback: DragSurface.ComputeSizeSignalCallback): number
|
|
4150
|
+
connect_after(sigName: "compute-size", callback: DragSurface.ComputeSizeSignalCallback): number
|
|
4151
|
+
emit(sigName: "compute-size", size: DragSurfaceSize, ...args: any[]): void
|
|
4152
|
+
|
|
4092
4153
|
// Class property signals of Gdk-4.0.Gdk.DragSurface
|
|
4093
4154
|
|
|
4094
4155
|
connect(sigName: "notify::cursor", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
@@ -4106,6 +4167,9 @@ interface DragSurface extends Surface {
|
|
|
4106
4167
|
connect(sigName: "notify::mapped", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4107
4168
|
connect_after(sigName: "notify::mapped", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4108
4169
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
4170
|
+
connect(sigName: "notify::scale", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4171
|
+
connect_after(sigName: "notify::scale", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4172
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
4109
4173
|
connect(sigName: "notify::scale-factor", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4110
4174
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: DragSurface, pspec: GObject.ParamSpec) => void)): number
|
|
4111
4175
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -4583,6 +4647,9 @@ interface Popup extends Surface {
|
|
|
4583
4647
|
connect(sigName: "notify::mapped", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4584
4648
|
connect_after(sigName: "notify::mapped", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4585
4649
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
4650
|
+
connect(sigName: "notify::scale", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4651
|
+
connect_after(sigName: "notify::scale", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4652
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
4586
4653
|
connect(sigName: "notify::scale-factor", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4587
4654
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: Popup, pspec: GObject.ParamSpec) => void)): number
|
|
4588
4655
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -4968,6 +5035,9 @@ interface Toplevel extends Surface {
|
|
|
4968
5035
|
connect(sigName: "notify::mapped", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4969
5036
|
connect_after(sigName: "notify::mapped", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4970
5037
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
5038
|
+
connect(sigName: "notify::scale", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
5039
|
+
connect_after(sigName: "notify::scale", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
5040
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
4971
5041
|
connect(sigName: "notify::scale-factor", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4972
5042
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: Toplevel, pspec: GObject.ParamSpec) => void)): number
|
|
4973
5043
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -7175,8 +7245,7 @@ interface Display {
|
|
|
7175
7245
|
*/
|
|
7176
7246
|
prepare_gl(): boolean
|
|
7177
7247
|
/**
|
|
7178
|
-
*
|
|
7179
|
-
* queue for `display`.
|
|
7248
|
+
* Adds the given event to the event queue for `display`.
|
|
7180
7249
|
* @param event a `GdkEvent`
|
|
7181
7250
|
*/
|
|
7182
7251
|
put_event(event: Event): void
|
|
@@ -8254,6 +8323,8 @@ interface Event {
|
|
|
8254
8323
|
get_pointer_emulated(): boolean
|
|
8255
8324
|
/**
|
|
8256
8325
|
* Extract the event surface relative x/y coordinates from an event.
|
|
8326
|
+
*
|
|
8327
|
+
* This position is in [surface coordinates](coordinates.html).
|
|
8257
8328
|
*/
|
|
8258
8329
|
get_position(): [ /* returnType */ boolean, /* x */ number, /* y */ number ]
|
|
8259
8330
|
/**
|
|
@@ -8684,9 +8755,6 @@ interface GLContext {
|
|
|
8684
8755
|
* Retrieves the OpenGL version of the `context`.
|
|
8685
8756
|
*
|
|
8686
8757
|
* The `context` must be realized prior to calling this function.
|
|
8687
|
-
*
|
|
8688
|
-
* If the `context` has never been made current, the version cannot
|
|
8689
|
-
* be known and it will return 0 for both `major` and `minor`.
|
|
8690
8758
|
*/
|
|
8691
8759
|
get_version(): [ /* major */ number, /* minor */ number ]
|
|
8692
8760
|
/**
|
|
@@ -8989,6 +9057,337 @@ class GLTexture extends Texture {
|
|
|
8989
9057
|
_init(config?: GLTexture.ConstructorProperties): void
|
|
8990
9058
|
}
|
|
8991
9059
|
|
|
9060
|
+
module GLTextureBuilder {
|
|
9061
|
+
|
|
9062
|
+
// Constructor properties interface
|
|
9063
|
+
|
|
9064
|
+
interface ConstructorProperties extends GObject.Object.ConstructorProperties {
|
|
9065
|
+
|
|
9066
|
+
// Own constructor properties of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9067
|
+
|
|
9068
|
+
/**
|
|
9069
|
+
* The context owning the texture.
|
|
9070
|
+
*/
|
|
9071
|
+
context?: GLContext | null
|
|
9072
|
+
/**
|
|
9073
|
+
* The format when downloading the texture.
|
|
9074
|
+
*/
|
|
9075
|
+
format?: MemoryFormat | null
|
|
9076
|
+
/**
|
|
9077
|
+
* If the texture has a mipmap.
|
|
9078
|
+
*/
|
|
9079
|
+
has_mipmap?: boolean | null
|
|
9080
|
+
/**
|
|
9081
|
+
* The height of the texture.
|
|
9082
|
+
*/
|
|
9083
|
+
height?: number | null
|
|
9084
|
+
/**
|
|
9085
|
+
* The texture ID to use.
|
|
9086
|
+
*/
|
|
9087
|
+
id?: number | null
|
|
9088
|
+
/**
|
|
9089
|
+
* An optional `GLSync` object.
|
|
9090
|
+
*
|
|
9091
|
+
* If this is set, GTK will wait on it before using the texture.
|
|
9092
|
+
*/
|
|
9093
|
+
sync?: any | null
|
|
9094
|
+
/**
|
|
9095
|
+
* The update region for [property`Gdk`.GLTextureBuilder:update-texture].
|
|
9096
|
+
*/
|
|
9097
|
+
update_region?: cairo.Region | null
|
|
9098
|
+
/**
|
|
9099
|
+
* The texture [property`Gdk`.GLTextureBuilder:update-region] is an update for.
|
|
9100
|
+
*/
|
|
9101
|
+
update_texture?: Texture | null
|
|
9102
|
+
/**
|
|
9103
|
+
* The width of the texture.
|
|
9104
|
+
*/
|
|
9105
|
+
width?: number | null
|
|
9106
|
+
}
|
|
9107
|
+
|
|
9108
|
+
}
|
|
9109
|
+
|
|
9110
|
+
interface GLTextureBuilder {
|
|
9111
|
+
|
|
9112
|
+
// Own properties of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9113
|
+
|
|
9114
|
+
/**
|
|
9115
|
+
* The context owning the texture.
|
|
9116
|
+
*/
|
|
9117
|
+
context: GLContext
|
|
9118
|
+
/**
|
|
9119
|
+
* The format when downloading the texture.
|
|
9120
|
+
*/
|
|
9121
|
+
format: MemoryFormat
|
|
9122
|
+
/**
|
|
9123
|
+
* If the texture has a mipmap.
|
|
9124
|
+
*/
|
|
9125
|
+
has_mipmap: boolean
|
|
9126
|
+
/**
|
|
9127
|
+
* The height of the texture.
|
|
9128
|
+
*/
|
|
9129
|
+
height: number
|
|
9130
|
+
/**
|
|
9131
|
+
* The texture ID to use.
|
|
9132
|
+
*/
|
|
9133
|
+
id: number
|
|
9134
|
+
/**
|
|
9135
|
+
* An optional `GLSync` object.
|
|
9136
|
+
*
|
|
9137
|
+
* If this is set, GTK will wait on it before using the texture.
|
|
9138
|
+
*/
|
|
9139
|
+
sync: any
|
|
9140
|
+
/**
|
|
9141
|
+
* The update region for [property`Gdk`.GLTextureBuilder:update-texture].
|
|
9142
|
+
*/
|
|
9143
|
+
update_region: cairo.Region
|
|
9144
|
+
/**
|
|
9145
|
+
* The texture [property`Gdk`.GLTextureBuilder:update-region] is an update for.
|
|
9146
|
+
*/
|
|
9147
|
+
update_texture: Texture
|
|
9148
|
+
/**
|
|
9149
|
+
* The width of the texture.
|
|
9150
|
+
*/
|
|
9151
|
+
width: number
|
|
9152
|
+
|
|
9153
|
+
// Owm methods of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9154
|
+
|
|
9155
|
+
/**
|
|
9156
|
+
* Builds a new `GdkTexture` with the values set up in the builder.
|
|
9157
|
+
*
|
|
9158
|
+
* The `destroy` function gets called when the returned texture gets released;
|
|
9159
|
+
* either when the texture is finalized or by an explicit call to
|
|
9160
|
+
* [method`Gdk`.GLTexture.release]. It should release all GL resources associated
|
|
9161
|
+
* with the texture, such as the [property`Gdk`.GLTextureBuilder:id] and the
|
|
9162
|
+
* [property`Gdk`.GLTextureBuilder:sync].
|
|
9163
|
+
*
|
|
9164
|
+
* Note that it is a programming error to call this function if any mandatory
|
|
9165
|
+
* property has not been set.
|
|
9166
|
+
*
|
|
9167
|
+
* It is possible to call this function multiple times to create multiple textures,
|
|
9168
|
+
* possibly with changing properties in between.
|
|
9169
|
+
* @param destroy destroy function to be called when the texture is released
|
|
9170
|
+
* @param data user data to pass to the destroy function
|
|
9171
|
+
* @returns a newly built `GdkTexture`
|
|
9172
|
+
*/
|
|
9173
|
+
build(destroy: GLib.DestroyNotify | null, data: any | null): Texture
|
|
9174
|
+
/**
|
|
9175
|
+
* Gets the context previously set via gdk_gl_texture_builder_set_context() or
|
|
9176
|
+
* %NULL if none was set.
|
|
9177
|
+
* @returns The context
|
|
9178
|
+
*/
|
|
9179
|
+
get_context(): GLContext | null
|
|
9180
|
+
/**
|
|
9181
|
+
* Gets the format previously set via gdk_gl_texture_builder_set_format().
|
|
9182
|
+
* @returns The format
|
|
9183
|
+
*/
|
|
9184
|
+
get_format(): MemoryFormat
|
|
9185
|
+
/**
|
|
9186
|
+
* Gets whether the texture has a mipmap.
|
|
9187
|
+
* @returns Whether the texture has a mipmap
|
|
9188
|
+
*/
|
|
9189
|
+
get_has_mipmap(): boolean
|
|
9190
|
+
/**
|
|
9191
|
+
* Gets the height previously set via gdk_gl_texture_builder_set_height() or
|
|
9192
|
+
* 0 if the height wasn't set.
|
|
9193
|
+
* @returns The height
|
|
9194
|
+
*/
|
|
9195
|
+
get_height(): number
|
|
9196
|
+
/**
|
|
9197
|
+
* Gets the texture id previously set via gdk_gl_texture_builder_set_id() or
|
|
9198
|
+
* 0 if the id wasn't set.
|
|
9199
|
+
* @returns The id
|
|
9200
|
+
*/
|
|
9201
|
+
get_id(): number
|
|
9202
|
+
/**
|
|
9203
|
+
* Gets the `GLsync` previously set via gdk_gl_texture_builder_set_sync().
|
|
9204
|
+
* @returns the `GLSync`
|
|
9205
|
+
*/
|
|
9206
|
+
get_sync(): any | null
|
|
9207
|
+
/**
|
|
9208
|
+
* Gets the region previously set via gdk_gl_texture_builder_set_update_region() or
|
|
9209
|
+
* %NULL if none was set.
|
|
9210
|
+
* @returns The region
|
|
9211
|
+
*/
|
|
9212
|
+
get_update_region(): cairo.Region | null
|
|
9213
|
+
/**
|
|
9214
|
+
* Gets the texture previously set via gdk_gl_texture_builder_set_update_texture() or
|
|
9215
|
+
* %NULL if none was set.
|
|
9216
|
+
* @returns The texture
|
|
9217
|
+
*/
|
|
9218
|
+
get_update_texture(): Texture | null
|
|
9219
|
+
/**
|
|
9220
|
+
* Gets the width previously set via gdk_gl_texture_builder_set_width() or
|
|
9221
|
+
* 0 if the width wasn't set.
|
|
9222
|
+
* @returns The width
|
|
9223
|
+
*/
|
|
9224
|
+
get_width(): number
|
|
9225
|
+
/**
|
|
9226
|
+
* Sets the context to be used for the texture. This is the context that owns
|
|
9227
|
+
* the texture.
|
|
9228
|
+
*
|
|
9229
|
+
* The context must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9230
|
+
* @param context The context the texture beongs to or %NULL to unset
|
|
9231
|
+
*/
|
|
9232
|
+
set_context(context: GLContext | null): void
|
|
9233
|
+
/**
|
|
9234
|
+
* Sets the format of the texture. The default is `GDK_MEMORY_R8G8B8A8_PREMULTIPLIED`.
|
|
9235
|
+
*
|
|
9236
|
+
* The format is the preferred format the texture data should be downloaded to. The
|
|
9237
|
+
* format must be supported by the GL version of [property`Gdk`.GLTextureBuilder:context].
|
|
9238
|
+
*
|
|
9239
|
+
* GDK's texture download code assumes that the format corresponds to the storage
|
|
9240
|
+
* parameters of the GL texture in an obvious way. For example, a format of
|
|
9241
|
+
* `GDK_MEMORY_R16G16B16A16_PREMULTIPLIED` is expected to be stored as `GL_RGBA16`
|
|
9242
|
+
* texture, and `GDK_MEMORY_G8A8` is expected to be stored as `GL_RG8` texture.
|
|
9243
|
+
*
|
|
9244
|
+
* Setting the right format is particularly useful when using high bit depth textures
|
|
9245
|
+
* to preserve the bit depth, to set the correct value for unpremultiplied textures
|
|
9246
|
+
* and to make sure opaque textures are treated as such.
|
|
9247
|
+
*
|
|
9248
|
+
* Non-RGBA textures need to have swizzling parameters set up properly to be usable
|
|
9249
|
+
* in GSK's shaders.
|
|
9250
|
+
* @param format The texture's format
|
|
9251
|
+
*/
|
|
9252
|
+
set_format(format: MemoryFormat): void
|
|
9253
|
+
/**
|
|
9254
|
+
* Sets whether the texture has a mipmap. This allows the renderer and other users of the
|
|
9255
|
+
* generated texture to use a higher quality downscaling.
|
|
9256
|
+
*
|
|
9257
|
+
* Typically, the `glGenerateMipmap` function is used to generate a mimap.
|
|
9258
|
+
* @param has_mipmap Whether the texture has a mipmap
|
|
9259
|
+
*/
|
|
9260
|
+
set_has_mipmap(has_mipmap: boolean): void
|
|
9261
|
+
/**
|
|
9262
|
+
* Sets the height of the texture.
|
|
9263
|
+
*
|
|
9264
|
+
* The height must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9265
|
+
* @param height The texture's height or 0 to unset
|
|
9266
|
+
*/
|
|
9267
|
+
set_height(height: number): void
|
|
9268
|
+
/**
|
|
9269
|
+
* Sets the texture id of the texture. The texture id must remain unmodified
|
|
9270
|
+
* until the texture was finalized. See [method`Gdk`.GLTextureBuilder.build]
|
|
9271
|
+
* for a longer discussion.
|
|
9272
|
+
*
|
|
9273
|
+
* The id must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9274
|
+
* @param id The texture id to be used for creating the texture
|
|
9275
|
+
*/
|
|
9276
|
+
set_id(id: number): void
|
|
9277
|
+
/**
|
|
9278
|
+
* Sets the GLSync object to use for the texture.
|
|
9279
|
+
*
|
|
9280
|
+
* GTK will wait on this object before using the created `GdkTexture`.
|
|
9281
|
+
*
|
|
9282
|
+
* The `destroy` function that is passed to [method`Gdk`.GLTextureBuilder.build]
|
|
9283
|
+
* is responsible for freeing the sync object when it is no longer needed.
|
|
9284
|
+
* The texture builder does not destroy it and it is the callers
|
|
9285
|
+
* responsibility to make sure it doesn't leak.
|
|
9286
|
+
* @param sync the GLSync object
|
|
9287
|
+
*/
|
|
9288
|
+
set_sync(sync: any | null): void
|
|
9289
|
+
/**
|
|
9290
|
+
* Sets the region to be updated by this texture. Together with
|
|
9291
|
+
* [property`Gdk`.GLTextureBuilder:update-texture] this describes an
|
|
9292
|
+
* update of a previous texture.
|
|
9293
|
+
*
|
|
9294
|
+
* When rendering animations of large textures, it is possible that
|
|
9295
|
+
* consecutive textures are only updating contents in parts of the texture.
|
|
9296
|
+
* It is then possible to describe this update via these two properties,
|
|
9297
|
+
* so that GTK can avoid rerendering parts that did not change.
|
|
9298
|
+
*
|
|
9299
|
+
* An example would be a screen recording where only the mouse pointer moves.
|
|
9300
|
+
* @param region the region to update
|
|
9301
|
+
*/
|
|
9302
|
+
set_update_region(region: cairo.Region | null): void
|
|
9303
|
+
/**
|
|
9304
|
+
* Sets the texture to be updated by this texture. See
|
|
9305
|
+
* [method`Gdk`.GLTextureBuilder.set_update_region] for an explanation.
|
|
9306
|
+
* @param texture the texture to update
|
|
9307
|
+
*/
|
|
9308
|
+
set_update_texture(texture: Texture | null): void
|
|
9309
|
+
/**
|
|
9310
|
+
* Sets the width of the texture.
|
|
9311
|
+
*
|
|
9312
|
+
* The width must be set before calling [method`Gdk`.GLTextureBuilder.build].
|
|
9313
|
+
* @param width The texture's width or 0 to unset
|
|
9314
|
+
*/
|
|
9315
|
+
set_width(width: number): void
|
|
9316
|
+
|
|
9317
|
+
// Class property signals of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9318
|
+
|
|
9319
|
+
connect(sigName: "notify::context", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9320
|
+
connect_after(sigName: "notify::context", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9321
|
+
emit(sigName: "notify::context", ...args: any[]): void
|
|
9322
|
+
connect(sigName: "notify::format", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9323
|
+
connect_after(sigName: "notify::format", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9324
|
+
emit(sigName: "notify::format", ...args: any[]): void
|
|
9325
|
+
connect(sigName: "notify::has-mipmap", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9326
|
+
connect_after(sigName: "notify::has-mipmap", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9327
|
+
emit(sigName: "notify::has-mipmap", ...args: any[]): void
|
|
9328
|
+
connect(sigName: "notify::height", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9329
|
+
connect_after(sigName: "notify::height", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9330
|
+
emit(sigName: "notify::height", ...args: any[]): void
|
|
9331
|
+
connect(sigName: "notify::id", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9332
|
+
connect_after(sigName: "notify::id", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9333
|
+
emit(sigName: "notify::id", ...args: any[]): void
|
|
9334
|
+
connect(sigName: "notify::sync", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9335
|
+
connect_after(sigName: "notify::sync", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9336
|
+
emit(sigName: "notify::sync", ...args: any[]): void
|
|
9337
|
+
connect(sigName: "notify::update-region", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9338
|
+
connect_after(sigName: "notify::update-region", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9339
|
+
emit(sigName: "notify::update-region", ...args: any[]): void
|
|
9340
|
+
connect(sigName: "notify::update-texture", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9341
|
+
connect_after(sigName: "notify::update-texture", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9342
|
+
emit(sigName: "notify::update-texture", ...args: any[]): void
|
|
9343
|
+
connect(sigName: "notify::width", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9344
|
+
connect_after(sigName: "notify::width", callback: (($obj: GLTextureBuilder, pspec: GObject.ParamSpec) => void)): number
|
|
9345
|
+
emit(sigName: "notify::width", ...args: any[]): void
|
|
9346
|
+
connect(sigName: string, callback: (...args: any[]) => void): number
|
|
9347
|
+
connect_after(sigName: string, callback: (...args: any[]) => void): number
|
|
9348
|
+
emit(sigName: string, ...args: any[]): void
|
|
9349
|
+
disconnect(id: number): void
|
|
9350
|
+
}
|
|
9351
|
+
|
|
9352
|
+
/**
|
|
9353
|
+
* `GdkGLTextureBuilder` is a buider used to construct [class`Gdk`.Texture] objects from
|
|
9354
|
+
* GL textures.
|
|
9355
|
+
*
|
|
9356
|
+
* The operation is quite simple: Create a texture builder, set all the necessary
|
|
9357
|
+
* properties - keep in mind that the properties [property`Gdk`.GLTextureBuilder:context],
|
|
9358
|
+
* [property`Gdk`.GLTextureBuilder:id], [property`Gdk`.GLTextureBuilder:width], and
|
|
9359
|
+
* [property`Gdk`.GLTextureBuilder:height] are mandatory - and then call
|
|
9360
|
+
* [method`Gdk`.GLTextureBuilder.build] to create the new texture.
|
|
9361
|
+
*
|
|
9362
|
+
* `GdkGLTextureBuilder` can be used for quick one-shot construction of
|
|
9363
|
+
* textures as well as kept around and reused to construct multiple textures.
|
|
9364
|
+
* @class
|
|
9365
|
+
*/
|
|
9366
|
+
class GLTextureBuilder extends GObject.Object {
|
|
9367
|
+
|
|
9368
|
+
// Own properties of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9369
|
+
|
|
9370
|
+
static name: string
|
|
9371
|
+
static $gtype: GObject.GType<GLTextureBuilder>
|
|
9372
|
+
|
|
9373
|
+
// Constructors of Gdk-4.0.Gdk.GLTextureBuilder
|
|
9374
|
+
|
|
9375
|
+
constructor(config?: GLTextureBuilder.ConstructorProperties)
|
|
9376
|
+
/**
|
|
9377
|
+
* Creates a new texture builder.
|
|
9378
|
+
* @constructor
|
|
9379
|
+
* @returns the new `GdkTextureBuilder`
|
|
9380
|
+
*/
|
|
9381
|
+
constructor()
|
|
9382
|
+
/**
|
|
9383
|
+
* Creates a new texture builder.
|
|
9384
|
+
* @constructor
|
|
9385
|
+
* @returns the new `GdkTextureBuilder`
|
|
9386
|
+
*/
|
|
9387
|
+
static new(): GLTextureBuilder
|
|
9388
|
+
_init(config?: GLTextureBuilder.ConstructorProperties): void
|
|
9389
|
+
}
|
|
9390
|
+
|
|
8992
9391
|
interface GrabBrokenEvent {
|
|
8993
9392
|
|
|
8994
9393
|
// Owm methods of Gdk-4.0.Gdk.GrabBrokenEvent
|
|
@@ -9775,8 +10174,15 @@ interface Surface {
|
|
|
9775
10174
|
* Whether the surface is mapped.
|
|
9776
10175
|
*/
|
|
9777
10176
|
readonly mapped: boolean
|
|
10177
|
+
/**
|
|
10178
|
+
* The scale of the surface.
|
|
10179
|
+
*/
|
|
10180
|
+
readonly scale: number
|
|
9778
10181
|
/**
|
|
9779
10182
|
* The scale factor of the surface.
|
|
10183
|
+
*
|
|
10184
|
+
* The scale factor is the next larger integer,
|
|
10185
|
+
* compared to [property`Gdk`.Surface:scale].
|
|
9780
10186
|
*/
|
|
9781
10187
|
readonly scale_factor: number
|
|
9782
10188
|
/**
|
|
@@ -9910,6 +10316,21 @@ interface Surface {
|
|
|
9910
10316
|
* @returns %TRUE if the surface is mapped
|
|
9911
10317
|
*/
|
|
9912
10318
|
get_mapped(): boolean
|
|
10319
|
+
/**
|
|
10320
|
+
* Returns the internal scale that maps from surface coordinates
|
|
10321
|
+
* to the actual device pixels.
|
|
10322
|
+
*
|
|
10323
|
+
* When the scale is bigger than 1, the windowing system prefers to get
|
|
10324
|
+
* buffers with a resolution that is bigger than the surface size (e.g.
|
|
10325
|
+
* to show the surface on a high-resolution display, or in a magnifier).
|
|
10326
|
+
*
|
|
10327
|
+
* Compare with [method`Gdk`.Surface.get_scale_factor], which returns the
|
|
10328
|
+
* next larger integer.
|
|
10329
|
+
*
|
|
10330
|
+
* The scale may change during the lifetime of the surface.
|
|
10331
|
+
* @returns the scale
|
|
10332
|
+
*/
|
|
10333
|
+
get_scale(): number
|
|
9913
10334
|
/**
|
|
9914
10335
|
* Returns the internal scale factor that maps from surface coordinates
|
|
9915
10336
|
* to the actual device pixels.
|
|
@@ -9921,7 +10342,7 @@ interface Surface {
|
|
|
9921
10342
|
* pixel-based data the scale value can be used to determine whether to
|
|
9922
10343
|
* use a pixel resource with higher resolution data.
|
|
9923
10344
|
*
|
|
9924
|
-
* The scale
|
|
10345
|
+
* The scale factor may change during the lifetime of the surface.
|
|
9925
10346
|
* @returns the scale factor
|
|
9926
10347
|
*/
|
|
9927
10348
|
get_scale_factor(): number
|
|
@@ -10069,6 +10490,9 @@ interface Surface {
|
|
|
10069
10490
|
connect(sigName: "notify::mapped", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10070
10491
|
connect_after(sigName: "notify::mapped", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10071
10492
|
emit(sigName: "notify::mapped", ...args: any[]): void
|
|
10493
|
+
connect(sigName: "notify::scale", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10494
|
+
connect_after(sigName: "notify::scale", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10495
|
+
emit(sigName: "notify::scale", ...args: any[]): void
|
|
10072
10496
|
connect(sigName: "notify::scale-factor", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10073
10497
|
connect_after(sigName: "notify::scale-factor", callback: (($obj: Surface, pspec: GObject.ParamSpec) => void)): number
|
|
10074
10498
|
emit(sigName: "notify::scale-factor", ...args: any[]): void
|
|
@@ -10285,7 +10709,8 @@ interface Texture extends Paintable, Gio.Icon, Gio.LoadableIcon {
|
|
|
10285
10709
|
* multiple frames, and will be used for a long time.
|
|
10286
10710
|
*
|
|
10287
10711
|
* There are various ways to create `GdkTexture` objects from a
|
|
10288
|
-
* [class`GdkPixbuf`.Pixbuf], or
|
|
10712
|
+
* [class`GdkPixbuf`.Pixbuf], or from bytes stored in memory, a file, or a
|
|
10713
|
+
* [struct`Gio`.Resource].
|
|
10289
10714
|
*
|
|
10290
10715
|
* The ownership of the pixel data is transferred to the `GdkTexture`
|
|
10291
10716
|
* instance; you can only make a copy of it, via [method`Gdk`.Texture.download].
|
|
@@ -10853,6 +11278,30 @@ abstract class DragSurfaceInterface {
|
|
|
10853
11278
|
static name: string
|
|
10854
11279
|
}
|
|
10855
11280
|
|
|
11281
|
+
interface DragSurfaceSize {
|
|
11282
|
+
|
|
11283
|
+
// Owm methods of Gdk-4.0.Gdk.DragSurfaceSize
|
|
11284
|
+
|
|
11285
|
+
/**
|
|
11286
|
+
* Sets the size the drag surface prefers to be resized to.
|
|
11287
|
+
* @param width the width
|
|
11288
|
+
* @param height the height
|
|
11289
|
+
*/
|
|
11290
|
+
set_size(width: number, height: number): void
|
|
11291
|
+
}
|
|
11292
|
+
|
|
11293
|
+
/**
|
|
11294
|
+
* The `GdkDragSurfaceSize` struct contains information that is useful
|
|
11295
|
+
* to compute the size of a drag surface.
|
|
11296
|
+
* @record
|
|
11297
|
+
*/
|
|
11298
|
+
class DragSurfaceSize {
|
|
11299
|
+
|
|
11300
|
+
// Own properties of Gdk-4.0.Gdk.DragSurfaceSize
|
|
11301
|
+
|
|
11302
|
+
static name: string
|
|
11303
|
+
}
|
|
11304
|
+
|
|
10856
11305
|
interface EventSequence {
|
|
10857
11306
|
}
|
|
10858
11307
|
|
|
@@ -11032,6 +11481,16 @@ class FrameTimings {
|
|
|
11032
11481
|
static name: string
|
|
11033
11482
|
}
|
|
11034
11483
|
|
|
11484
|
+
interface GLTextureBuilderClass {
|
|
11485
|
+
}
|
|
11486
|
+
|
|
11487
|
+
abstract class GLTextureBuilderClass {
|
|
11488
|
+
|
|
11489
|
+
// Own properties of Gdk-4.0.Gdk.GLTextureBuilderClass
|
|
11490
|
+
|
|
11491
|
+
static name: string
|
|
11492
|
+
}
|
|
11493
|
+
|
|
11035
11494
|
interface GLTextureClass {
|
|
11036
11495
|
}
|
|
11037
11496
|
|
|
@@ -11594,10 +12053,10 @@ interface TextureDownloader {
|
|
|
11594
12053
|
* be stored in the stride value.
|
|
11595
12054
|
*
|
|
11596
12055
|
* This function will abort if it tries to download a large texture and
|
|
11597
|
-
* fails to allocate memory. If you think that may happen, you should
|
|
11598
|
-
*
|
|
11599
|
-
*
|
|
11600
|
-
* @returns The downloaded pixels
|
|
12056
|
+
* fails to allocate memory. If you think that may happen, you should handle
|
|
12057
|
+
* memory allocation yourself and use [method`Gdk`.TextureDownloader.download_into]
|
|
12058
|
+
* once allocation succeeded.
|
|
12059
|
+
* @returns The downloaded pixels
|
|
11601
12060
|
*/
|
|
11602
12061
|
download_bytes(): [ /* returnType */ GLib.Bytes, /* out_stride */ number ]
|
|
11603
12062
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@girs/gdk-4.0",
|
|
3
|
-
"version": "4.0.0-3.2.
|
|
3
|
+
"version": "4.0.0-3.2.4",
|
|
4
4
|
"description": "GJS TypeScript type definitions for Gdk-4.0, generated from library version 4.0.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "gdk-4.0.js",
|
|
@@ -25,17 +25,17 @@
|
|
|
25
25
|
"test:cjs": "NODE_OPTIONS=--max_old_space_size=9216 tsc --noEmit gdk-4.0.d.cts"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@girs/cairo-1.0": "^1.0.0-3.2.
|
|
29
|
-
"@girs/freetype2-2.0": "^2.0.0-3.2.
|
|
30
|
-
"@girs/gdkpixbuf-2.0": "^2.0.0-3.2.
|
|
31
|
-
"@girs/gio-2.0": "^2.
|
|
32
|
-
"@girs/gjs": "^3.2.
|
|
33
|
-
"@girs/glib-2.0": "^2.
|
|
34
|
-
"@girs/gmodule-2.0": "^2.0.0-3.2.
|
|
35
|
-
"@girs/gobject-2.0": "^2.
|
|
36
|
-
"@girs/harfbuzz-0.0": "^
|
|
37
|
-
"@girs/pango-1.0": "^1.
|
|
38
|
-
"@girs/pangocairo-1.0": "^1.0.0-3.2.
|
|
28
|
+
"@girs/cairo-1.0": "^1.0.0-3.2.4",
|
|
29
|
+
"@girs/freetype2-2.0": "^2.0.0-3.2.4",
|
|
30
|
+
"@girs/gdkpixbuf-2.0": "^2.0.0-3.2.4",
|
|
31
|
+
"@girs/gio-2.0": "^2.78.0-3.2.4",
|
|
32
|
+
"@girs/gjs": "^3.2.4",
|
|
33
|
+
"@girs/glib-2.0": "^2.78.0-3.2.4",
|
|
34
|
+
"@girs/gmodule-2.0": "^2.0.0-3.2.4",
|
|
35
|
+
"@girs/gobject-2.0": "^2.78.0-3.2.4",
|
|
36
|
+
"@girs/harfbuzz-0.0": "^8.2.1-3.2.4",
|
|
37
|
+
"@girs/pango-1.0": "^1.51.0-3.2.4",
|
|
38
|
+
"@girs/pangocairo-1.0": "^1.0.0-3.2.4"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"typescript": "*"
|