@girs/foundrygtk-1 4.2.0 → 4.4.0

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 CHANGED
@@ -5,25 +5,25 @@
5
5
  ![downloads/week](https://img.shields.io/npm/dw/@girs/foundrygtk-1)
6
6
 
7
7
 
8
- GJS TypeScript type definitions for FoundryGtk-1 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v4.2.0.
8
+ GJS TypeScript type definitions for FoundryGtk-1 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v4.4.0.
9
9
 
10
10
  ## Install
11
11
 
12
- To use this type definitions, install them with NPM:
12
+ Install the type definitions with npm:
13
13
  ```bash
14
14
  npm install @girs/foundrygtk-1
15
15
  ```
16
16
 
17
17
  ## Usage
18
18
 
19
- You can import this package into your project like this:
19
+ Import it like any other module:
20
20
  ```ts
21
21
  import FoundryGtk from '@girs/foundrygtk-1';
22
22
  ```
23
23
 
24
24
  ### Ambient Modules
25
25
 
26
- You can also use [ambient modules](https://github.com/gjsify/ts-for-gir/tree/main/packages/cli#ambient-modules) to import this module like you would do this in JavaScript.
26
+ [Ambient modules](https://github.com/gjsify/ts-for-gir/tree/main/packages/cli#ambient-modules) let you write the same import you would in plain JavaScript.
27
27
  For this you need to include `@girs/foundrygtk-1` or `@girs/foundrygtk-1/ambient` in your `tsconfig` or entry point Typescript file:
28
28
 
29
29
  `index.ts`:
@@ -42,7 +42,7 @@ import '@girs/foundrygtk-1'
42
42
  }
43
43
  ```
44
44
 
45
- Now you can import the ambient module with TypeScript support:
45
+ The ambient module now resolves with types:
46
46
 
47
47
  ```ts
48
48
  import FoundryGtk from 'gi://FoundryGtk?version=1';
@@ -50,7 +50,7 @@ import FoundryGtk from 'gi://FoundryGtk?version=1';
50
50
 
51
51
  ### Global import
52
52
 
53
- You can also import the module with Typescript support using the global `imports.gi` object of GJS.
53
+ GJS's global `imports.gi` works too, with types.
54
54
  For this you need to include `@girs/foundrygtk-1` or `@girs/foundrygtk-1/import` in your `tsconfig` or entry point Typescript file:
55
55
 
56
56
  `index.ts`:
@@ -69,7 +69,7 @@ import '@girs/foundrygtk-1'
69
69
  }
70
70
  ```
71
71
 
72
- Now you have also type support for this, too:
72
+ That form carries types as well:
73
73
 
74
74
  ```ts
75
75
  const FoundryGtk = imports.gi.FoundryGtk;
@@ -77,7 +77,7 @@ const FoundryGtk = imports.gi.FoundryGtk;
77
77
 
78
78
  ### Bundle
79
79
 
80
- Depending on your project configuration, it is recommended to use a bundler like [esbuild](https://esbuild.github.io/). You can find examples using different bundlers [here](https://github.com/gjsify/ts-for-gir/tree/main/examples).
80
+ Most projects want a bundler. [esbuild](https://esbuild.github.io/) is the smallest thing that works; the [examples directory](https://github.com/gjsify/ts-for-gir/tree/main/examples) has setups for several others.
81
81
 
82
82
  ## Other packages
83
83
 
@@ -3,7 +3,7 @@
3
3
  *
4
4
  * GENERATED — do not edit. Provenance: FoundryGtk-1 — dropped empty base(s): GObject.InitiallyUnowned GObject.Object
5
5
  *
6
- * 5 concrete widgets, 5 declarations, 0 enum nick unions, 0 slot candidates.
6
+ * 6 concrete widgets, 6 declarations, 0 enum nick unions, 0 slot candidates.
7
7
  *
8
8
  * Module-scoped exports only. There is no `JSX` namespace here, no tag spelling and
9
9
  * no `on<Signal>` prop name: those are DIALECT, and every framework answers them
@@ -64,6 +64,17 @@ export interface FoundryDiagnosticsGutterRendererProps extends GtkSourceGutterRe
64
64
  /** Settable only at construction — a renderer must REBUILD, not patch. */
65
65
  export type FoundryDiagnosticsGutterRendererConstructOnly = GtkSourceGutterRendererConstructOnly | GtkAccessibleConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly;
66
66
 
67
+ /** A widget that displays Git graph lanes for a [class@Foundry.VcsGraphEntry]. */
68
+ export interface FoundryGitLanesProps extends GtkWidgetProps, GtkAccessibleProps, GtkBuildableProps, GtkConstraintTargetProps {
69
+ /**
70
+ * The graph entry to render.
71
+ * @since 1.2
72
+ */
73
+ entry?: Foundry.VcsGraphEntry;
74
+ }
75
+ /** Settable only at construction — a renderer must REBUILD, not patch. */
76
+ export type FoundryGitLanesConstructOnly = GtkWidgetConstructOnly | GtkAccessibleConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly;
77
+
67
78
  export interface FoundryMarkupViewProps extends GtkWidgetProps, GtkAccessibleProps, GtkBuildableProps, GtkConstraintTargetProps {
68
79
  }
69
80
  /** Settable only at construction — a renderer must REBUILD, not patch. */
@@ -122,6 +133,13 @@ export interface Widgets {
122
133
  constructOnly: FoundryDiagnosticsGutterRendererConstructOnly;
123
134
  slotCandidates: {};
124
135
  };
136
+ FoundryGitLanes: {
137
+ class: FoundryGtk.GitLanes;
138
+ props: FoundryGitLanesProps;
139
+ signals: FoundryGtk.GitLanes.SignalSignatures;
140
+ constructOnly: FoundryGitLanesConstructOnly;
141
+ slotCandidates: {};
142
+ };
125
143
  FoundryMarkupView: {
126
144
  class: FoundryGtk.MarkupView;
127
145
  props: FoundryMarkupViewProps;
@@ -148,6 +166,23 @@ export interface Widgets {
148
166
  /** Every GType this namespace can create. A consumer derives its own tag map. */
149
167
  export type WidgetGType = keyof Widgets;
150
168
 
169
+ // ---------------------------------------------------------------------------
170
+ // Child holders — the same shape, for objects that CARRY a widget without being one.
171
+ //
172
+ // `GtkListItem`, `GtkListHeader`, `GtkColumnViewCell` and `AdwToggle` descend from
173
+ // `GObject.Object` and hold a widget through `set_child`/`get_child`. A renderer places
174
+ // them exactly like a container, so they belong in the vocabulary; a check asking "is
175
+ // this a widget" must still be able to say no. Hence a sibling table rather than four
176
+ // more rows in `Widgets`: concatenate them when you mean both.
177
+ // ---------------------------------------------------------------------------
178
+
179
+ export interface ChildHolders {
180
+
181
+ }
182
+
183
+ /** Every GType this namespace holds a child in without it being a widget. */
184
+ export type ChildHolderGType = keyof ChildHolders;
185
+
151
186
  /** The writable, optional, GObject-keyed property surface of one GType. */
152
187
  export type PropsOf<G extends WidgetGType> = Widgets[G]['props'];
153
188
 
@@ -183,6 +218,9 @@ export const OWN_SIGNALS: Readonly<Record<string, readonly string[]>>;
183
218
  /** Widget GType -> every declaration its members come from, self first. */
184
219
  export const DECLS: Readonly<Record<string, readonly string[]>>;
185
220
 
221
+ /** The GTypes in `DECLS` that hold a widget without being one — see `ChildHolders`. */
222
+ export const CHILD_HOLDERS: readonly string[];
223
+
186
224
  /** Enum GType -> the nicks this surface offers. */
187
225
  export const ENUM_NICKS: Readonly<Record<string, readonly string[]>>;
188
226
 
@@ -11,6 +11,7 @@ export const SURFACE_PROVENANCE = 'FoundryGtk-1 — dropped empty base(s): GObje
11
11
  export const OWN_PROPS = {
12
12
  FoundryChangesGutterRenderer: ['show-overview'],
13
13
  FoundryDiagnosticsGutterRenderer: ['diagnostics'],
14
+ FoundryGitLanes: ['entry'],
14
15
  FoundrySourceView: ['document', 'enable-completion', 'enable-vim', 'font', 'line-height', 'show-diagnostics', 'show-line-changes', 'show-line-changes-overview'],
15
16
  FoundryTerminal: ['palette'],
16
17
  };
@@ -20,13 +21,22 @@ export const OWN_SIGNALS = {};
20
21
  export const DECLS = {
21
22
  FoundryChangesGutterRenderer: ['FoundryChangesGutterRenderer', 'GtkSourceGutterRenderer', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
22
23
  FoundryDiagnosticsGutterRenderer: ['FoundryDiagnosticsGutterRenderer', 'GtkSourceGutterRenderer', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
24
+ FoundryGitLanes: ['FoundryGitLanes', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
23
25
  FoundryMarkupView: ['FoundryMarkupView', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
24
26
  FoundrySourceView: ['FoundrySourceView', 'GtkSourceView', 'GtkTextView', 'GtkWidget', 'GtkAccessible', 'GtkAccessibleText', 'GtkBuildable', 'GtkConstraintTarget', 'GtkScrollable'],
25
27
  FoundryTerminal: ['FoundryTerminal', 'GtkWidget', 'GtkAccessible', 'GtkAccessibleText', 'GtkBuildable', 'GtkConstraintTarget', 'GtkScrollable'],
26
28
  };
27
29
 
30
+ // The GTypes above that are NOT widgets: they hold one through `set_child`/`get_child`
31
+ // and descend from `GObject.Object`. A renderer places them like a container; a check
32
+ // asking "is this a widget" must not count them. Derived from the accessor pair, never
33
+ // from a list — the count is in the provenance line above.
34
+ export const CHILD_HOLDERS = [];
35
+
28
36
  export const ENUM_NICKS = {};
29
37
 
30
38
  export const SLOT_CANDIDATES = {};
31
39
 
32
- export const SINCE = {};
40
+ export const SINCE = {
41
+ 'FoundryGitLanes.entry': '1.2',
42
+ };
package/foundrygtk-1.d.ts CHANGED
@@ -30,6 +30,7 @@ import type freetype2 from '@girs/freetype2-2.0';
30
30
  import type GdkPixbuf from '@girs/gdkpixbuf-2.0';
31
31
  import type Foundry from '@girs/foundry-1';
32
32
  import type Dex from '@girs/dex-1';
33
+ import type GioUnix from '@girs/giounix-2.0';
33
34
 
34
35
  export namespace FoundryGtk {
35
36
 
@@ -271,6 +272,489 @@ export namespace FoundryGtk {
271
272
  }
272
273
 
273
274
 
275
+ namespace GitLanes {
276
+ // Signal signatures
277
+ interface SignalSignatures extends Gtk.Widget.SignalSignatures {
278
+ "notify::entry": (pspec: GObject.ParamSpec) => void;
279
+ "notify::can-focus": (pspec: GObject.ParamSpec) => void;
280
+ "notify::can-target": (pspec: GObject.ParamSpec) => void;
281
+ "notify::css-classes": (pspec: GObject.ParamSpec) => void;
282
+ "notify::css-name": (pspec: GObject.ParamSpec) => void;
283
+ "notify::cursor": (pspec: GObject.ParamSpec) => void;
284
+ "notify::focus-on-click": (pspec: GObject.ParamSpec) => void;
285
+ "notify::focusable": (pspec: GObject.ParamSpec) => void;
286
+ "notify::halign": (pspec: GObject.ParamSpec) => void;
287
+ "notify::has-default": (pspec: GObject.ParamSpec) => void;
288
+ "notify::has-focus": (pspec: GObject.ParamSpec) => void;
289
+ "notify::has-tooltip": (pspec: GObject.ParamSpec) => void;
290
+ "notify::height-request": (pspec: GObject.ParamSpec) => void;
291
+ "notify::hexpand": (pspec: GObject.ParamSpec) => void;
292
+ "notify::hexpand-set": (pspec: GObject.ParamSpec) => void;
293
+ "notify::layout-manager": (pspec: GObject.ParamSpec) => void;
294
+ "notify::limit-events": (pspec: GObject.ParamSpec) => void;
295
+ "notify::margin-bottom": (pspec: GObject.ParamSpec) => void;
296
+ "notify::margin-end": (pspec: GObject.ParamSpec) => void;
297
+ "notify::margin-start": (pspec: GObject.ParamSpec) => void;
298
+ "notify::margin-top": (pspec: GObject.ParamSpec) => void;
299
+ "notify::name": (pspec: GObject.ParamSpec) => void;
300
+ "notify::opacity": (pspec: GObject.ParamSpec) => void;
301
+ "notify::overflow": (pspec: GObject.ParamSpec) => void;
302
+ "notify::parent": (pspec: GObject.ParamSpec) => void;
303
+ "notify::receives-default": (pspec: GObject.ParamSpec) => void;
304
+ "notify::root": (pspec: GObject.ParamSpec) => void;
305
+ "notify::scale-factor": (pspec: GObject.ParamSpec) => void;
306
+ "notify::sensitive": (pspec: GObject.ParamSpec) => void;
307
+ "notify::tooltip-markup": (pspec: GObject.ParamSpec) => void;
308
+ "notify::tooltip-text": (pspec: GObject.ParamSpec) => void;
309
+ "notify::valign": (pspec: GObject.ParamSpec) => void;
310
+ "notify::vexpand": (pspec: GObject.ParamSpec) => void;
311
+ "notify::vexpand-set": (pspec: GObject.ParamSpec) => void;
312
+ "notify::visible": (pspec: GObject.ParamSpec) => void;
313
+ "notify::width-request": (pspec: GObject.ParamSpec) => void;
314
+ "notify::accessible-role": (pspec: GObject.ParamSpec) => void;
315
+ }
316
+
317
+ // Constructor properties interface
318
+ interface ConstructorProps extends Gtk.Widget.ConstructorProps, Gtk.Accessible.ConstructorProps, Gtk.Buildable.ConstructorProps, Gtk.ConstraintTarget.ConstructorProps {
319
+ entry: Foundry.VcsGraphEntry;
320
+ }
321
+ }
322
+
323
+ /**
324
+ * A widget that displays Git graph lanes for a {@link Foundry.VcsGraphEntry}.
325
+ * @gir-type Class
326
+ * @since 1.2
327
+ */
328
+ class GitLanes extends Gtk.Widget implements Gtk.Accessible, Gtk.Buildable, Gtk.ConstraintTarget {
329
+ static $gtype: GObject.GType<GitLanes>;
330
+
331
+ // Properties
332
+ /**
333
+ * The graph entry to render.
334
+ * @since 1.2
335
+ */
336
+ get entry(): Foundry.VcsGraphEntry;
337
+ set entry(val: Foundry.VcsGraphEntry);
338
+
339
+ /**
340
+ * Compile-time signal type information.
341
+ *
342
+ * This instance property is generated only for TypeScript type checking.
343
+ * It is not defined at runtime and should not be accessed in JS code.
344
+ * @internal
345
+ */
346
+ $signals: GitLanes.SignalSignatures;
347
+
348
+ // Constructors
349
+ constructor(properties?: Partial<GitLanes.ConstructorProps>, ...args: any[]);
350
+
351
+ _init(...args: any[]): void;
352
+
353
+ static ["new"](): GitLanes;
354
+
355
+ // Signals
356
+ /** @signal */
357
+ connect<K extends keyof GitLanes.SignalSignatures>(signal: K, callback: GObject.SignalCallback<this, GitLanes.SignalSignatures[K]>): number;
358
+ connect(signal: string, callback: (...args: any[]) => any): number;
359
+
360
+ /** @signal */
361
+ connect_after<K extends keyof GitLanes.SignalSignatures>(signal: K, callback: GObject.SignalCallback<this, GitLanes.SignalSignatures[K]>): number;
362
+ connect_after(signal: string, callback: (...args: any[]) => any): number;
363
+
364
+ /** @signal */
365
+ emit<K extends keyof GitLanes.SignalSignatures>(signal: K, ...args: GObject.GjsParameters<GitLanes.SignalSignatures[K]> extends [any, ...infer Q] ? Q : never): void;
366
+ emit(signal: string, ...args: any[]): void;
367
+
368
+ // Methods
369
+ /**
370
+ * Gets the graph entry displayed by `self`.
371
+ * @returns a {@link Foundry.VcsGraphEntry}
372
+ * @since 1.2
373
+ */
374
+ dup_entry(): Foundry.VcsGraphEntry | null;
375
+
376
+ /**
377
+ * Sets the graph entry displayed by `self`.
378
+ * @param entry a {@link Foundry.VcsGraphEntry}
379
+ * @since 1.2
380
+ */
381
+ set_entry(entry: Foundry.VcsGraphEntry | null): void;
382
+
383
+ /**
384
+ * Sets the colors to use when drawing graph lanes.
385
+ *
386
+ * If `colors` is `null`, the default lane colors are used. When `colors` is not
387
+ * `null`, the colors are copied and `n_colors` must be greater than zero.
388
+ * @param colors the lane colors
389
+ * @since 1.2
390
+ */
391
+ set_lane_colors(colors: Gdk.RGBA[] | null): void;
392
+
393
+ /**
394
+ * The accessible role of the given {@link Gtk.Accessible} implementation.
395
+ *
396
+ * The accessible role cannot be changed once set.
397
+ * @default Gtk.AccessibleRole.NONE
398
+ * @category Inherited from Gtk.Accessible
399
+ */
400
+ get accessible_role(): Gtk.AccessibleRole;
401
+ set accessible_role(val: Gtk.AccessibleRole);
402
+
403
+ /**
404
+ * The accessible role of the given {@link Gtk.Accessible} implementation.
405
+ *
406
+ * The accessible role cannot be changed once set.
407
+ * @default Gtk.AccessibleRole.NONE
408
+ * @category Inherited from Gtk.Accessible
409
+ */
410
+ get accessibleRole(): Gtk.AccessibleRole;
411
+ set accessibleRole(val: Gtk.AccessibleRole);
412
+
413
+ /**
414
+ * Requests the user's screen reader to announce the given message.
415
+ *
416
+ * This kind of notification is useful for messages that
417
+ * either have only a visual representation or that are not
418
+ * exposed visually at all, e.g. a notification about a
419
+ * successful operation.
420
+ *
421
+ * Also, by using this API, you can ensure that the message
422
+ * does not interrupts the user's current screen reader output.
423
+ * @param message the string to announce
424
+ * @param priority the priority of the announcement
425
+ * @since 4.14
426
+ */
427
+ announce(message: string, priority: Gtk.AccessibleAnnouncementPriority): void;
428
+
429
+ /**
430
+ * Retrieves the accessible identifier for the accessible object.
431
+ *
432
+ * This functionality can be overridden by {@link Gtk.Accessible}
433
+ * implementations.
434
+ *
435
+ * It is left to the accessible implementation to define the scope
436
+ * and uniqueness of the identifier.
437
+ * @returns the accessible identifier
438
+ * @since 4.22
439
+ */
440
+ get_accessible_id(): string | null;
441
+
442
+ /**
443
+ * Retrieves the accessible parent for an accessible object.
444
+ *
445
+ * This function returns `NULL` for top level widgets.
446
+ * @returns the accessible parent
447
+ * @since 4.10
448
+ */
449
+ get_accessible_parent(): Gtk.Accessible | null;
450
+
451
+ /**
452
+ * Retrieves the accessible role of an accessible object.
453
+ * @returns the accessible role
454
+ */
455
+ get_accessible_role(): Gtk.AccessibleRole;
456
+
457
+ /**
458
+ * Retrieves the implementation for the given accessible object.
459
+ * @returns the accessible implementation object
460
+ * @since 4.10
461
+ */
462
+ get_at_context(): Gtk.ATContext;
463
+
464
+ /**
465
+ * Queries the coordinates and dimensions of this accessible
466
+ *
467
+ * This functionality can be overridden by {@link Gtk.Accessible}
468
+ * implementations, e.g. to get the bounds from an ignored
469
+ * child widget.
470
+ * @returns true if the bounds are valid, and false otherwise
471
+ * @since 4.10
472
+ */
473
+ get_bounds(): [boolean, number, number, number, number];
474
+
475
+ /**
476
+ * Retrieves the first accessible child of an accessible object.
477
+ * @returns the first accessible child
478
+ * @since 4.10
479
+ */
480
+ get_first_accessible_child(): Gtk.Accessible | null;
481
+
482
+ /**
483
+ * Retrieves the next accessible sibling of an accessible object
484
+ * @returns the next accessible sibling
485
+ * @since 4.10
486
+ */
487
+ get_next_accessible_sibling(): Gtk.Accessible | null;
488
+
489
+ /**
490
+ * Queries a platform state, such as focus.
491
+ *
492
+ * This functionality can be overridden by {@link Gtk.Accessible}
493
+ * implementations, e.g. to get platform state from an ignored
494
+ * child widget, as is the case for {@link Gtk.Text} wrappers.
495
+ * @param state platform state to query
496
+ * @returns the value of state for the accessible
497
+ * @since 4.10
498
+ */
499
+ get_platform_state(state: Gtk.AccessiblePlatformState): boolean;
500
+
501
+ /**
502
+ * Resets the accessible property to its default value.
503
+ * @param property the accessible property
504
+ */
505
+ reset_property(property: Gtk.AccessibleProperty): void;
506
+
507
+ /**
508
+ * Resets the accessible relation to its default value.
509
+ * @param relation the accessible relation
510
+ */
511
+ reset_relation(relation: Gtk.AccessibleRelation): void;
512
+
513
+ /**
514
+ * Resets the accessible state to its default value.
515
+ * @param state the accessible state
516
+ */
517
+ reset_state(state: Gtk.AccessibleState): void;
518
+
519
+ /**
520
+ * Sets the parent and sibling of an accessible object.
521
+ *
522
+ * This function is meant to be used by accessible implementations that are
523
+ * not part of the widget hierarchy, and but act as a logical bridge between
524
+ * widgets. For instance, if a widget creates an object that holds metadata
525
+ * for each child, and you want that object to implement the {@link Gtk.Accessible}
526
+ * interface, you will use this function to ensure that the parent of each
527
+ * child widget is the metadata object, and the parent of each metadata
528
+ * object is the container widget.
529
+ * @param parent the parent accessible object
530
+ * @param next_sibling the sibling accessible object
531
+ * @since 4.10
532
+ */
533
+ set_accessible_parent(parent: Gtk.Accessible | null, next_sibling: Gtk.Accessible | null): void;
534
+
535
+ /**
536
+ * Updates the next accessible sibling.
537
+ *
538
+ * That might be useful when a new child of a custom accessible
539
+ * is created, and it needs to be linked to a previous child.
540
+ * @param new_sibling the new next accessible sibling to set
541
+ * @since 4.10
542
+ */
543
+ update_next_accessible_sibling(new_sibling: Gtk.Accessible | null): void;
544
+
545
+ /**
546
+ * Informs ATs that the platform state has changed.
547
+ *
548
+ * This function should be used by {@link Gtk.Accessible} implementations that
549
+ * have a platform state but are not widgets. Widgets handle platform
550
+ * states automatically.
551
+ * @param state the platform state to update
552
+ * @since 4.18
553
+ */
554
+ update_platform_state(state: Gtk.AccessiblePlatformState): void;
555
+
556
+ /**
557
+ * Updates an array of accessible properties.
558
+ *
559
+ * This function should be called by {@link Gtk.Widget} types whenever an accessible
560
+ * property change must be communicated to assistive technologies.
561
+ *
562
+ * This function is meant to be used by language bindings.
563
+ * @param properties an array of accessible properties
564
+ * @param values an array of `GValues`, one for each property
565
+ */
566
+ update_property(properties: Gtk.AccessibleProperty[], values: (GObject.Value | any)[]): void;
567
+
568
+ /**
569
+ * Updates an array of accessible relations.
570
+ *
571
+ * This function should be called by {@link Gtk.Widget} types whenever an accessible
572
+ * relation change must be communicated to assistive technologies.
573
+ *
574
+ * This function is meant to be used by language bindings.
575
+ * @param relations an array of accessible relations
576
+ * @param values an array of `GValues`, one for each relation
577
+ */
578
+ update_relation(relations: Gtk.AccessibleRelation[], values: (GObject.Value | any)[]): void;
579
+
580
+ /**
581
+ * Updates an array of accessible states.
582
+ *
583
+ * This function should be called by {@link Gtk.Widget} types whenever an accessible
584
+ * state change must be communicated to assistive technologies.
585
+ *
586
+ * This function is meant to be used by language bindings.
587
+ * @param states an array of accessible states
588
+ * @param values an array of `GValues`, one for each state
589
+ */
590
+ update_state(states: Gtk.AccessibleState[], values: (GObject.Value | any)[]): void;
591
+
592
+ /**
593
+ * Retrieves the accessible identifier for the accessible object.
594
+ *
595
+ * This functionality can be overridden by {@link Gtk.Accessible}
596
+ * implementations.
597
+ *
598
+ * It is left to the accessible implementation to define the scope
599
+ * and uniqueness of the identifier.
600
+ * @since 4.22
601
+ * @virtual
602
+ */
603
+ vfunc_get_accessible_id(): string | null;
604
+
605
+ /**
606
+ * Retrieves the accessible parent for an accessible object.
607
+ *
608
+ * This function returns `NULL` for top level widgets.
609
+ * @since 4.10
610
+ * @virtual
611
+ */
612
+ vfunc_get_accessible_parent(): Gtk.Accessible | null;
613
+
614
+ /**
615
+ * Retrieves the implementation for the given accessible object.
616
+ * @since 4.10
617
+ * @virtual
618
+ */
619
+ vfunc_get_at_context(): Gtk.ATContext | null;
620
+
621
+ /**
622
+ * Queries the coordinates and dimensions of this accessible
623
+ *
624
+ * This functionality can be overridden by {@link Gtk.Accessible}
625
+ * implementations, e.g. to get the bounds from an ignored
626
+ * child widget.
627
+ * @since 4.10
628
+ * @virtual
629
+ */
630
+ vfunc_get_bounds(): [boolean, number, number, number, number];
631
+
632
+ /**
633
+ * Retrieves the first accessible child of an accessible object.
634
+ * @since 4.10
635
+ * @virtual
636
+ */
637
+ vfunc_get_first_accessible_child(): Gtk.Accessible | null;
638
+
639
+ /**
640
+ * Retrieves the next accessible sibling of an accessible object
641
+ * @since 4.10
642
+ * @virtual
643
+ */
644
+ vfunc_get_next_accessible_sibling(): Gtk.Accessible | null;
645
+
646
+ /**
647
+ * Queries a platform state, such as focus.
648
+ *
649
+ * This functionality can be overridden by {@link Gtk.Accessible}
650
+ * implementations, e.g. to get platform state from an ignored
651
+ * child widget, as is the case for {@link Gtk.Text} wrappers.
652
+ * @param state platform state to query
653
+ * @since 4.10
654
+ * @virtual
655
+ */
656
+ vfunc_get_platform_state(state: Gtk.AccessiblePlatformState): boolean;
657
+
658
+ /**
659
+ * Gets the ID of the `buildable` object.
660
+ *
661
+ * {@link Gtk.Builder} sets the name based on the ID attribute
662
+ * of the `<object>` tag used to construct the `buildable`.
663
+ * @returns the ID of the buildable object
664
+ */
665
+ get_buildable_id(): string | null;
666
+
667
+ /**
668
+ * Adds a child to `buildable`. `type` is an optional string
669
+ * describing how the child should be added.
670
+ * @param builder a {@link Gtk.Builder}
671
+ * @param child child to add
672
+ * @param type kind of child or `null`
673
+ * @virtual
674
+ */
675
+ vfunc_add_child(builder: Gtk.Builder, child: GObject.Object, type: string | null): void;
676
+
677
+ /**
678
+ * Similar to `gtk_buildable_parser_finished()` but is
679
+ * called once for each custom tag handled by the `buildable`.
680
+ * @param builder a {@link Gtk.Builder}
681
+ * @param child child object or `null` for non-child tags
682
+ * @param tagname the name of the tag
683
+ * @param data user data created in custom_tag_start
684
+ * @virtual
685
+ */
686
+ vfunc_custom_finished(builder: Gtk.Builder, child: GObject.Object | null, tagname: string, data: null): void;
687
+
688
+ /**
689
+ * Called at the end of each custom element handled by
690
+ * the buildable.
691
+ * @param builder {@link Gtk.Builder} used to construct this object
692
+ * @param child child object or `null` for non-child tags
693
+ * @param tagname name of tag
694
+ * @param data user data that will be passed in to parser functions
695
+ * @virtual
696
+ */
697
+ vfunc_custom_tag_end(builder: Gtk.Builder, child: GObject.Object | null, tagname: string, data: null): void;
698
+
699
+ /**
700
+ * Called for each unknown element under `<child>`.
701
+ * @param builder a {@link Gtk.Builder} used to construct this object
702
+ * @param child child object or `null` for non-child tags
703
+ * @param tagname name of tag
704
+ * @virtual
705
+ */
706
+ vfunc_custom_tag_start(builder: Gtk.Builder, child: GObject.Object | null, tagname: string): [boolean, Gtk.BuildableParser, never];
707
+
708
+ /**
709
+ * The getter corresponding to `set_id`. Implement this
710
+ * if you implement `set_id`.
711
+ * @virtual
712
+ */
713
+ vfunc_get_id(): string;
714
+
715
+ /**
716
+ * Retrieves the internal child called `childname` of the `buildable` object.
717
+ * @param builder a {@link Gtk.Builder}
718
+ * @param childname name of child
719
+ * @virtual
720
+ */
721
+ vfunc_get_internal_child<T = GObject.Object>(builder: Gtk.Builder, childname: string): T;
722
+
723
+ /**
724
+ * Called when a builder finishes the parsing
725
+ * of a UI definition. It is normally not necessary to implement this,
726
+ * unless you need to perform special cleanup actions. {@link Gtk.Window} sets
727
+ * the {@link Gtk.Widget.visible} property here.
728
+ * @param builder
729
+ * @virtual
730
+ */
731
+ vfunc_parser_finished(builder: Gtk.Builder): void;
732
+
733
+ /**
734
+ * Sets a property of a buildable object.
735
+ * It is normally not necessary to implement this, `g_object_set_property()`
736
+ * is used by default. {@link Gtk.Window} implements this to delay showing itself
737
+ * (i.e. setting the {@link Gtk.Widget.visible} property) until the whole
738
+ * interface is created.
739
+ * @param builder
740
+ * @param name
741
+ * @param value
742
+ * @virtual
743
+ */
744
+ vfunc_set_buildable_property(builder: Gtk.Builder, name: string, value: unknown): void;
745
+
746
+ /**
747
+ * Stores the id attribute given in the {@link Gtk.Builder} UI definition.
748
+ * {@link Gtk.Widget} stores the name as object data. Implement this method if your
749
+ * object has some notion of “ID” and it makes sense to map the XML id
750
+ * attribute to it.
751
+ * @param id
752
+ * @virtual
753
+ */
754
+ vfunc_set_id(id: string): void;
755
+ }
756
+
757
+
274
758
  namespace MarkupView {
275
759
  // Signal signatures
276
760
  interface SignalSignatures extends Gtk.Widget.SignalSignatures {
@@ -389,6 +873,7 @@ export namespace FoundryGtk {
389
873
  * does not interrupts the user's current screen reader output.
390
874
  * @param message the string to announce
391
875
  * @param priority the priority of the announcement
876
+ * @since 4.14
392
877
  */
393
878
  announce(message: string, priority: Gtk.AccessibleAnnouncementPriority): void;
394
879
 
@@ -401,6 +886,7 @@ export namespace FoundryGtk {
401
886
  * It is left to the accessible implementation to define the scope
402
887
  * and uniqueness of the identifier.
403
888
  * @returns the accessible identifier
889
+ * @since 4.22
404
890
  */
405
891
  get_accessible_id(): string | null;
406
892
 
@@ -409,6 +895,7 @@ export namespace FoundryGtk {
409
895
  *
410
896
  * This function returns `NULL` for top level widgets.
411
897
  * @returns the accessible parent
898
+ * @since 4.10
412
899
  */
413
900
  get_accessible_parent(): Gtk.Accessible | null;
414
901
 
@@ -421,6 +908,7 @@ export namespace FoundryGtk {
421
908
  /**
422
909
  * Retrieves the implementation for the given accessible object.
423
910
  * @returns the accessible implementation object
911
+ * @since 4.10
424
912
  */
425
913
  get_at_context(): Gtk.ATContext;
426
914
 
@@ -431,18 +919,21 @@ export namespace FoundryGtk {
431
919
  * implementations, e.g. to get the bounds from an ignored
432
920
  * child widget.
433
921
  * @returns true if the bounds are valid, and false otherwise
922
+ * @since 4.10
434
923
  */
435
924
  get_bounds(): [boolean, number, number, number, number];
436
925
 
437
926
  /**
438
927
  * Retrieves the first accessible child of an accessible object.
439
928
  * @returns the first accessible child
929
+ * @since 4.10
440
930
  */
441
931
  get_first_accessible_child(): Gtk.Accessible | null;
442
932
 
443
933
  /**
444
934
  * Retrieves the next accessible sibling of an accessible object
445
935
  * @returns the next accessible sibling
936
+ * @since 4.10
446
937
  */
447
938
  get_next_accessible_sibling(): Gtk.Accessible | null;
448
939
 
@@ -454,6 +945,7 @@ export namespace FoundryGtk {
454
945
  * child widget, as is the case for {@link Gtk.Text} wrappers.
455
946
  * @param state platform state to query
456
947
  * @returns the value of state for the accessible
948
+ * @since 4.10
457
949
  */
458
950
  get_platform_state(state: Gtk.AccessiblePlatformState): boolean;
459
951
 
@@ -487,6 +979,7 @@ export namespace FoundryGtk {
487
979
  * object is the container widget.
488
980
  * @param parent the parent accessible object
489
981
  * @param next_sibling the sibling accessible object
982
+ * @since 4.10
490
983
  */
491
984
  set_accessible_parent(parent: Gtk.Accessible | null, next_sibling: Gtk.Accessible | null): void;
492
985
 
@@ -496,6 +989,7 @@ export namespace FoundryGtk {
496
989
  * That might be useful when a new child of a custom accessible
497
990
  * is created, and it needs to be linked to a previous child.
498
991
  * @param new_sibling the new next accessible sibling to set
992
+ * @since 4.10
499
993
  */
500
994
  update_next_accessible_sibling(new_sibling: Gtk.Accessible | null): void;
501
995
 
@@ -506,6 +1000,7 @@ export namespace FoundryGtk {
506
1000
  * have a platform state but are not widgets. Widgets handle platform
507
1001
  * states automatically.
508
1002
  * @param state the platform state to update
1003
+ * @since 4.18
509
1004
  */
510
1005
  update_platform_state(state: Gtk.AccessiblePlatformState): void;
511
1006
 
@@ -553,6 +1048,7 @@ export namespace FoundryGtk {
553
1048
  *
554
1049
  * It is left to the accessible implementation to define the scope
555
1050
  * and uniqueness of the identifier.
1051
+ * @since 4.22
556
1052
  * @virtual
557
1053
  */
558
1054
  vfunc_get_accessible_id(): string | null;
@@ -561,12 +1057,14 @@ export namespace FoundryGtk {
561
1057
  * Retrieves the accessible parent for an accessible object.
562
1058
  *
563
1059
  * This function returns `NULL` for top level widgets.
1060
+ * @since 4.10
564
1061
  * @virtual
565
1062
  */
566
1063
  vfunc_get_accessible_parent(): Gtk.Accessible | null;
567
1064
 
568
1065
  /**
569
1066
  * Retrieves the implementation for the given accessible object.
1067
+ * @since 4.10
570
1068
  * @virtual
571
1069
  */
572
1070
  vfunc_get_at_context(): Gtk.ATContext | null;
@@ -577,18 +1075,21 @@ export namespace FoundryGtk {
577
1075
  * This functionality can be overridden by {@link Gtk.Accessible}
578
1076
  * implementations, e.g. to get the bounds from an ignored
579
1077
  * child widget.
1078
+ * @since 4.10
580
1079
  * @virtual
581
1080
  */
582
1081
  vfunc_get_bounds(): [boolean, number, number, number, number];
583
1082
 
584
1083
  /**
585
1084
  * Retrieves the first accessible child of an accessible object.
1085
+ * @since 4.10
586
1086
  * @virtual
587
1087
  */
588
1088
  vfunc_get_first_accessible_child(): Gtk.Accessible | null;
589
1089
 
590
1090
  /**
591
1091
  * Retrieves the next accessible sibling of an accessible object
1092
+ * @since 4.10
592
1093
  * @virtual
593
1094
  */
594
1095
  vfunc_get_next_accessible_sibling(): Gtk.Accessible | null;
@@ -600,6 +1101,7 @@ export namespace FoundryGtk {
600
1101
  * implementations, e.g. to get platform state from an ignored
601
1102
  * child widget, as is the case for {@link Gtk.Text} wrappers.
602
1103
  * @param state platform state to query
1104
+ * @since 4.10
603
1105
  * @virtual
604
1106
  */
605
1107
  vfunc_get_platform_state(state: Gtk.AccessiblePlatformState): boolean;
@@ -695,7 +1197,7 @@ export namespace FoundryGtk {
695
1197
  /**
696
1198
  * Stores the id attribute given in the {@link Gtk.Builder} UI definition.
697
1199
  * {@link Gtk.Widget} stores the name as object data. Implement this method if your
698
- * object has some notion of &#x201C;ID&#x201D; and it makes sense to map the XML id
1200
+ * object has some notion of ID and it makes sense to map the XML id
699
1201
  * attribute to it.
700
1202
  * @param id
701
1203
  * @virtual
@@ -777,6 +1279,7 @@ export namespace FoundryGtk {
777
1279
  /**
778
1280
  * @param resource
779
1281
  * @returns the merge id
1282
+ * @since 1.4
780
1283
  */
781
1284
  add_resource(resource: string): number;
782
1285
 
@@ -787,17 +1290,20 @@ export namespace FoundryGtk {
787
1290
  * If no match is found, `null` is returned.
788
1291
  * @param id the identifier of the menu item
789
1292
  * @returns a {@link Gio.Menu} if successful; otherwise `null` and `position` is unset.
1293
+ * @since 1.4
790
1294
  */
791
1295
  find_item_by_id(id: string): [Gio.Menu | null, number];
792
1296
 
793
1297
  /**
794
1298
  * @param menu_id
795
1299
  * @returns A {@link Gio.Menu}.
1300
+ * @since 1.4
796
1301
  */
797
1302
  get_menu_by_id(menu_id: string): Gio.Menu;
798
1303
 
799
1304
  /**
800
1305
  * Gets the known menu ids as a string array.
1306
+ * @since 1.4
801
1307
  */
802
1308
  get_menu_ids(): string[];
803
1309
 
@@ -806,6 +1312,7 @@ export namespace FoundryGtk {
806
1312
  * @param menu_id the identifier of the menu
807
1313
  * @param menu_model the menu model to merge
808
1314
  * @returns the merge-id which can be used with `foundry_menu_manager_remove()`
1315
+ * @since 1.4
809
1316
  */
810
1317
  merge(menu_id: string, menu_model: Gio.MenuModel): number;
811
1318
 
@@ -814,6 +1321,7 @@ export namespace FoundryGtk {
814
1321
  * menu merge. Use the value returned from `foundry_menu_manager_merge()` as
815
1322
  * the `merge_id`.
816
1323
  * @param merge_id A previously registered merge id
1324
+ * @since 1.4
817
1325
  */
818
1326
  remove(merge_id: number): void;
819
1327
 
@@ -827,6 +1335,7 @@ export namespace FoundryGtk {
827
1335
  * @param position the index of the item in the menu
828
1336
  * @param attribute the attribute to change
829
1337
  * @param value the new value for the attribute
1338
+ * @since 1.4
830
1339
  */
831
1340
  set_attribute_string(menu: Gio.Menu, position: number, attribute: string, value: string): void;
832
1341
  }
@@ -977,6 +1486,7 @@ export namespace FoundryGtk {
977
1486
  * The item type of a {@link Gio.ListModel} can not change during the life of the
978
1487
  * model.
979
1488
  * @returns the {@link GObject.GType} of the items contained in `list`.
1489
+ * @since 2.44
980
1490
  */
981
1491
  get_item_type(): GObject.GType;
982
1492
 
@@ -987,6 +1497,7 @@ export namespace FoundryGtk {
987
1497
  * less efficient than iterating the list with increasing values for
988
1498
  * `position` until `g_list_model_get_item()` returns `null`.
989
1499
  * @returns the number of items in `list`.
1500
+ * @since 2.44
990
1501
  */
991
1502
  get_n_items(): number;
992
1503
 
@@ -1005,6 +1516,7 @@ export namespace FoundryGtk {
1005
1516
  * See also: `g_list_model_get_n_items()`
1006
1517
  * @param position the position of the item to fetch
1007
1518
  * @returns the object at `position`.
1519
+ * @since 2.44
1008
1520
  */
1009
1521
  get_item(position: number): A | null;
1010
1522
 
@@ -1032,6 +1544,7 @@ export namespace FoundryGtk {
1032
1544
  * @param position the position at which `list` changed
1033
1545
  * @param removed the number of items removed
1034
1546
  * @param added the number of items added
1547
+ * @since 2.44
1035
1548
  */
1036
1549
  items_changed(position: number, removed: number, added: number): void;
1037
1550
 
@@ -1044,6 +1557,7 @@ export namespace FoundryGtk {
1044
1557
  *
1045
1558
  * The same {@link GObject.Object} instance may not appear more than once in a {@link Gio.ListModel}.
1046
1559
  * @param position the position of the item to fetch
1560
+ * @since 2.44
1047
1561
  * @virtual
1048
1562
  */
1049
1563
  vfunc_get_item(position: number): A | null;
@@ -1057,6 +1571,7 @@ export namespace FoundryGtk {
1057
1571
  *
1058
1572
  * The item type of a {@link Gio.ListModel} can not change during the life of the
1059
1573
  * model.
1574
+ * @since 2.44
1060
1575
  * @virtual
1061
1576
  */
1062
1577
  vfunc_get_item_type(): GObject.GType;
@@ -1067,6 +1582,7 @@ export namespace FoundryGtk {
1067
1582
  * Depending on the model implementation, calling this function may be
1068
1583
  * less efficient than iterating the list with increasing values for
1069
1584
  * `position` until `g_list_model_get_item()` returns `null`.
1585
+ * @since 2.44
1070
1586
  * @virtual
1071
1587
  */
1072
1588
  vfunc_get_n_items(): number;
@@ -1153,6 +1669,7 @@ export namespace FoundryGtk {
1153
1669
  * The item type of a {@link Gio.ListModel} can not change during the life of the
1154
1670
  * model.
1155
1671
  * @returns the {@link GObject.GType} of the items contained in `list`.
1672
+ * @since 2.44
1156
1673
  */
1157
1674
  get_item_type(): GObject.GType;
1158
1675
 
@@ -1163,6 +1680,7 @@ export namespace FoundryGtk {
1163
1680
  * less efficient than iterating the list with increasing values for
1164
1681
  * `position` until `g_list_model_get_item()` returns `null`.
1165
1682
  * @returns the number of items in `list`.
1683
+ * @since 2.44
1166
1684
  */
1167
1685
  get_n_items(): number;
1168
1686
 
@@ -1181,6 +1699,7 @@ export namespace FoundryGtk {
1181
1699
  * See also: `g_list_model_get_n_items()`
1182
1700
  * @param position the position of the item to fetch
1183
1701
  * @returns the object at `position`.
1702
+ * @since 2.44
1184
1703
  */
1185
1704
  get_item(position: number): A | null;
1186
1705
 
@@ -1208,6 +1727,7 @@ export namespace FoundryGtk {
1208
1727
  * @param position the position at which `list` changed
1209
1728
  * @param removed the number of items removed
1210
1729
  * @param added the number of items added
1730
+ * @since 2.44
1211
1731
  */
1212
1732
  items_changed(position: number, removed: number, added: number): void;
1213
1733
 
@@ -1220,6 +1740,7 @@ export namespace FoundryGtk {
1220
1740
  *
1221
1741
  * The same {@link GObject.Object} instance may not appear more than once in a {@link Gio.ListModel}.
1222
1742
  * @param position the position of the item to fetch
1743
+ * @since 2.44
1223
1744
  * @virtual
1224
1745
  */
1225
1746
  vfunc_get_item(position: number): A | null;
@@ -1233,6 +1754,7 @@ export namespace FoundryGtk {
1233
1754
  *
1234
1755
  * The item type of a {@link Gio.ListModel} can not change during the life of the
1235
1756
  * model.
1757
+ * @since 2.44
1236
1758
  * @virtual
1237
1759
  */
1238
1760
  vfunc_get_item_type(): GObject.GType;
@@ -1243,6 +1765,7 @@ export namespace FoundryGtk {
1243
1765
  * Depending on the model implementation, calling this function may be
1244
1766
  * less efficient than iterating the list with increasing values for
1245
1767
  * `position` until `g_list_model_get_item()` returns `null`.
1768
+ * @since 2.44
1246
1769
  * @virtual
1247
1770
  */
1248
1771
  vfunc_get_n_items(): number;
@@ -1431,6 +1954,7 @@ export namespace FoundryGtk {
1431
1954
  * for the current language.
1432
1955
  * @param begin start of the text range to comment
1433
1956
  * @param end end of the text range to comment
1957
+ * @since 1.1
1434
1958
  */
1435
1959
  comment(begin: Gtk.TextIter, end: Gtk.TextIter): void;
1436
1960
 
@@ -1469,6 +1993,7 @@ export namespace FoundryGtk {
1469
1993
  * Removes comment markers from the specified text range.
1470
1994
  * @param begin start of the text range to uncomment
1471
1995
  * @param end end of the text range to uncomment
1996
+ * @since 1.1
1472
1997
  */
1473
1998
  uncomment(begin: Gtk.TextIter, end: Gtk.TextIter): void;
1474
1999
 
@@ -1479,6 +2004,7 @@ export namespace FoundryGtk {
1479
2004
  * @param flags non-zero flags to dispatch
1480
2005
  * @param commit_notify
1481
2006
  * @returns a non-zero commit handler id if supported; otherwise zero.
2007
+ * @since 1.1
1482
2008
  */
1483
2009
  add_commit_notify(flags: Foundry.TextBufferNotifyFlags, commit_notify: Foundry.TextBufferCommitNotify): number;
1484
2010
 
@@ -1540,6 +2066,7 @@ export namespace FoundryGtk {
1540
2066
  /**
1541
2067
  * Remove a commit notify handler.
1542
2068
  * @param commit_notify_handler the previously registered non-zero commit handler
2069
+ * @since 1.1
1543
2070
  */
1544
2071
  remove_commit_notify(commit_notify_handler: number): void;
1545
2072
 
@@ -1556,6 +2083,7 @@ export namespace FoundryGtk {
1556
2083
  * If the implementation does not support this, zero is returned.
1557
2084
  * @param flags non-zero flags to dispatch
1558
2085
  * @param commit_notify
2086
+ * @since 1.1
1559
2087
  * @virtual
1560
2088
  */
1561
2089
  vfunc_add_commit_notify(flags: Foundry.TextBufferNotifyFlags, commit_notify: Foundry.TextBufferCommitNotify): number;
@@ -1596,6 +2124,7 @@ export namespace FoundryGtk {
1596
2124
  /**
1597
2125
  * Remove a commit notify handler.
1598
2126
  * @param commit_notify_handler the previously registered non-zero commit handler
2127
+ * @since 1.1
1599
2128
  * @virtual
1600
2129
  */
1601
2130
  vfunc_remove_commit_notify(commit_notify_handler: number): void;
@@ -1925,6 +2454,7 @@ export namespace FoundryGtk {
1925
2454
  * @param use_align
1926
2455
  * @param xalign
1927
2456
  * @param yalign
2457
+ * @since 1.1
1928
2458
  */
1929
2459
  jump_to_iter(iter: Gtk.TextIter, within_margin: number, use_align: boolean, xalign: number, yalign: number): void;
1930
2460
 
@@ -1982,12 +2512,12 @@ export namespace FoundryGtk {
1982
2512
  namespace SourceViewAddin {
1983
2513
  // Signal signatures
1984
2514
  interface SignalSignatures extends GObject.Object.SignalSignatures {
1985
- "notify::vie": (pspec: GObject.ParamSpec) => void;
2515
+ "notify::view": (pspec: GObject.ParamSpec) => void;
1986
2516
  }
1987
2517
 
1988
2518
  // Constructor properties interface
1989
2519
  interface ConstructorProps extends GObject.Object.ConstructorProps {
1990
- vie: SourceView;
2520
+ view: SourceView | null;
1991
2521
  }
1992
2522
  }
1993
2523
 
@@ -2001,7 +2531,7 @@ export namespace FoundryGtk {
2001
2531
  /**
2002
2532
  * @read-only
2003
2533
  */
2004
- get vie(): SourceView;
2534
+ get view(): SourceView | null;
2005
2535
 
2006
2536
  /**
2007
2537
  * Compile-time signal type information.
@@ -2032,7 +2562,7 @@ export namespace FoundryGtk {
2032
2562
 
2033
2563
  // Methods
2034
2564
  /**
2035
- * Gets teh view for the addin.
2565
+ * Gets the view for the addin.
2036
2566
  *
2037
2567
  * This will always be `null` before load has been called and after
2038
2568
  * unload has been called.
@@ -2234,6 +2764,7 @@ export namespace FoundryGtk {
2234
2764
  * does not interrupts the user's current screen reader output.
2235
2765
  * @param message the string to announce
2236
2766
  * @param priority the priority of the announcement
2767
+ * @since 4.14
2237
2768
  */
2238
2769
  announce(message: string, priority: Gtk.AccessibleAnnouncementPriority): void;
2239
2770
 
@@ -2246,6 +2777,7 @@ export namespace FoundryGtk {
2246
2777
  * It is left to the accessible implementation to define the scope
2247
2778
  * and uniqueness of the identifier.
2248
2779
  * @returns the accessible identifier
2780
+ * @since 4.22
2249
2781
  */
2250
2782
  get_accessible_id(): string | null;
2251
2783
 
@@ -2254,6 +2786,7 @@ export namespace FoundryGtk {
2254
2786
  *
2255
2787
  * This function returns `NULL` for top level widgets.
2256
2788
  * @returns the accessible parent
2789
+ * @since 4.10
2257
2790
  */
2258
2791
  get_accessible_parent(): Gtk.Accessible | null;
2259
2792
 
@@ -2266,6 +2799,7 @@ export namespace FoundryGtk {
2266
2799
  /**
2267
2800
  * Retrieves the implementation for the given accessible object.
2268
2801
  * @returns the accessible implementation object
2802
+ * @since 4.10
2269
2803
  */
2270
2804
  get_at_context(): Gtk.ATContext;
2271
2805
 
@@ -2276,18 +2810,21 @@ export namespace FoundryGtk {
2276
2810
  * implementations, e.g. to get the bounds from an ignored
2277
2811
  * child widget.
2278
2812
  * @returns true if the bounds are valid, and false otherwise
2813
+ * @since 4.10
2279
2814
  */
2280
2815
  get_bounds(): [boolean, number, number, number, number];
2281
2816
 
2282
2817
  /**
2283
2818
  * Retrieves the first accessible child of an accessible object.
2284
2819
  * @returns the first accessible child
2820
+ * @since 4.10
2285
2821
  */
2286
2822
  get_first_accessible_child(): Gtk.Accessible | null;
2287
2823
 
2288
2824
  /**
2289
2825
  * Retrieves the next accessible sibling of an accessible object
2290
2826
  * @returns the next accessible sibling
2827
+ * @since 4.10
2291
2828
  */
2292
2829
  get_next_accessible_sibling(): Gtk.Accessible | null;
2293
2830
 
@@ -2299,6 +2836,7 @@ export namespace FoundryGtk {
2299
2836
  * child widget, as is the case for {@link Gtk.Text} wrappers.
2300
2837
  * @param state platform state to query
2301
2838
  * @returns the value of state for the accessible
2839
+ * @since 4.10
2302
2840
  */
2303
2841
  get_platform_state(state: Gtk.AccessiblePlatformState): boolean;
2304
2842
 
@@ -2332,6 +2870,7 @@ export namespace FoundryGtk {
2332
2870
  * object is the container widget.
2333
2871
  * @param parent the parent accessible object
2334
2872
  * @param next_sibling the sibling accessible object
2873
+ * @since 4.10
2335
2874
  */
2336
2875
  set_accessible_parent(parent: Gtk.Accessible | null, next_sibling: Gtk.Accessible | null): void;
2337
2876
 
@@ -2341,6 +2880,7 @@ export namespace FoundryGtk {
2341
2880
  * That might be useful when a new child of a custom accessible
2342
2881
  * is created, and it needs to be linked to a previous child.
2343
2882
  * @param new_sibling the new next accessible sibling to set
2883
+ * @since 4.10
2344
2884
  */
2345
2885
  update_next_accessible_sibling(new_sibling: Gtk.Accessible | null): void;
2346
2886
 
@@ -2351,6 +2891,7 @@ export namespace FoundryGtk {
2351
2891
  * have a platform state but are not widgets. Widgets handle platform
2352
2892
  * states automatically.
2353
2893
  * @param state the platform state to update
2894
+ * @since 4.18
2354
2895
  */
2355
2896
  update_platform_state(state: Gtk.AccessiblePlatformState): void;
2356
2897
 
@@ -2398,6 +2939,7 @@ export namespace FoundryGtk {
2398
2939
  *
2399
2940
  * It is left to the accessible implementation to define the scope
2400
2941
  * and uniqueness of the identifier.
2942
+ * @since 4.22
2401
2943
  * @virtual
2402
2944
  */
2403
2945
  vfunc_get_accessible_id(): string | null;
@@ -2406,12 +2948,14 @@ export namespace FoundryGtk {
2406
2948
  * Retrieves the accessible parent for an accessible object.
2407
2949
  *
2408
2950
  * This function returns `NULL` for top level widgets.
2951
+ * @since 4.10
2409
2952
  * @virtual
2410
2953
  */
2411
2954
  vfunc_get_accessible_parent(): Gtk.Accessible | null;
2412
2955
 
2413
2956
  /**
2414
2957
  * Retrieves the implementation for the given accessible object.
2958
+ * @since 4.10
2415
2959
  * @virtual
2416
2960
  */
2417
2961
  vfunc_get_at_context(): Gtk.ATContext | null;
@@ -2422,18 +2966,21 @@ export namespace FoundryGtk {
2422
2966
  * This functionality can be overridden by {@link Gtk.Accessible}
2423
2967
  * implementations, e.g. to get the bounds from an ignored
2424
2968
  * child widget.
2969
+ * @since 4.10
2425
2970
  * @virtual
2426
2971
  */
2427
2972
  vfunc_get_bounds(): [boolean, number, number, number, number];
2428
2973
 
2429
2974
  /**
2430
2975
  * Retrieves the first accessible child of an accessible object.
2976
+ * @since 4.10
2431
2977
  * @virtual
2432
2978
  */
2433
2979
  vfunc_get_first_accessible_child(): Gtk.Accessible | null;
2434
2980
 
2435
2981
  /**
2436
2982
  * Retrieves the next accessible sibling of an accessible object
2983
+ * @since 4.10
2437
2984
  * @virtual
2438
2985
  */
2439
2986
  vfunc_get_next_accessible_sibling(): Gtk.Accessible | null;
@@ -2445,6 +2992,7 @@ export namespace FoundryGtk {
2445
2992
  * implementations, e.g. to get platform state from an ignored
2446
2993
  * child widget, as is the case for {@link Gtk.Text} wrappers.
2447
2994
  * @param state platform state to query
2995
+ * @since 4.10
2448
2996
  * @virtual
2449
2997
  */
2450
2998
  vfunc_get_platform_state(state: Gtk.AccessiblePlatformState): boolean;
@@ -2455,6 +3003,7 @@ export namespace FoundryGtk {
2455
3003
  * Implementations of the {@link Gtk.AccessibleText} interface should call this
2456
3004
  * function every time the caret has moved, in order to notify assistive
2457
3005
  * technologies.
3006
+ * @since 4.14
2458
3007
  */
2459
3008
  update_caret_position(): void;
2460
3009
 
@@ -2471,6 +3020,7 @@ export namespace FoundryGtk {
2471
3020
  * @param change the type of change in the contents
2472
3021
  * @param start the starting offset of the change, in characters
2473
3022
  * @param end the end offset of the change, in characters
3023
+ * @since 4.14
2474
3024
  */
2475
3025
  update_contents(change: Gtk.AccessibleTextContentChange, start: number, end: number): void;
2476
3026
 
@@ -2480,6 +3030,7 @@ export namespace FoundryGtk {
2480
3030
  * Implementations of the {@link Gtk.AccessibleText} interface should call this
2481
3031
  * function every time the selection has moved, in order to notify assistive
2482
3032
  * technologies.
3033
+ * @since 4.14
2483
3034
  */
2484
3035
  update_selection_bound(): void;
2485
3036
 
@@ -2502,12 +3053,14 @@ export namespace FoundryGtk {
2502
3053
  * greater than or equal to one, `ranges` will be set to a newly
2503
3054
  * allocated array of [struct#Gtk.AccessibleTextRange].
2504
3055
  * @param offset the offset, in characters
3056
+ * @since 4.14
2505
3057
  * @virtual
2506
3058
  */
2507
3059
  vfunc_get_attributes(offset: number): [boolean, Gtk.AccessibleTextRange[] | null, string[] | null, string[] | null];
2508
3060
 
2509
3061
  /**
2510
3062
  * Retrieves the position of the caret inside the accessible object.
3063
+ * @since 4.14
2511
3064
  * @virtual
2512
3065
  */
2513
3066
  vfunc_get_caret_position(): number;
@@ -2520,6 +3073,7 @@ export namespace FoundryGtk {
2520
3073
  * of the accessible object.
2521
3074
  * @param start the beginning of the range, in characters
2522
3075
  * @param end the end of the range, in characters
3076
+ * @since 4.14
2523
3077
  * @virtual
2524
3078
  */
2525
3079
  vfunc_get_contents(start: number, end: number): GLib.Bytes | Uint8Array;
@@ -2531,6 +3085,7 @@ export namespace FoundryGtk {
2531
3085
  * The `start` and `end` values contain the boundaries of the text.
2532
3086
  * @param offset the offset, in characters
2533
3087
  * @param granularity the granularity of the query
3088
+ * @since 4.14
2534
3089
  * @virtual
2535
3090
  */
2536
3091
  vfunc_get_contents_at(offset: number, granularity: Gtk.AccessibleTextGranularity): [GLib.Bytes | Uint8Array, number, number];
@@ -2548,6 +3103,7 @@ export namespace FoundryGtk {
2548
3103
  *
2549
3104
  * GTK provides support for various text attribute names and values, but
2550
3105
  * implementations of this interface are free to add their own attributes.
3106
+ * @since 4.14
2551
3107
  * @virtual
2552
3108
  */
2553
3109
  vfunc_get_default_attributes(): [string[] | null, string[] | null];
@@ -2557,6 +3113,7 @@ export namespace FoundryGtk {
2557
3113
  * @param start the start offset, in characters
2558
3114
  * @param end the end offset, in characters, `extents` (out caller-allocates): return location for the extents
2559
3115
  * @param extents
3116
+ * @since 4.16
2560
3117
  * @virtual
2561
3118
  */
2562
3119
  vfunc_get_extents(start: number, end: number, extents: Graphene.Rect): boolean;
@@ -2564,6 +3121,7 @@ export namespace FoundryGtk {
2564
3121
  /**
2565
3122
  * Gets the text offset at a given point.
2566
3123
  * @param point a point in widget coordinates of `self`
3124
+ * @since 4.16
2567
3125
  * @virtual
2568
3126
  */
2569
3127
  vfunc_get_offset(point: Graphene.Point): [boolean, number];
@@ -2574,6 +3132,7 @@ export namespace FoundryGtk {
2574
3132
  * If this function returns true, `n_ranges` will be set to a value
2575
3133
  * greater than or equal to one, and `ranges` will be set to a newly
2576
3134
  * allocated array of [struct#Gtk.AccessibleTextRange].
3135
+ * @since 4.14
2577
3136
  * @virtual
2578
3137
  */
2579
3138
  vfunc_get_selection(): [boolean, Gtk.AccessibleTextRange[] | null];
@@ -2581,6 +3140,7 @@ export namespace FoundryGtk {
2581
3140
  /**
2582
3141
  * Sets the caret position.
2583
3142
  * @param offset the text offset in characters
3143
+ * @since 4.22
2584
3144
  * @virtual
2585
3145
  */
2586
3146
  vfunc_set_caret_position(offset: number): boolean;
@@ -2589,6 +3149,7 @@ export namespace FoundryGtk {
2589
3149
  * Sets the caret position.
2590
3150
  * @param i the selection to set
2591
3151
  * @param range the range to set the selection to
3152
+ * @since 4.22
2592
3153
  * @virtual
2593
3154
  */
2594
3155
  vfunc_set_selection(i: number, range: Gtk.AccessibleTextRange): boolean;
@@ -2684,7 +3245,7 @@ export namespace FoundryGtk {
2684
3245
  /**
2685
3246
  * Stores the id attribute given in the {@link Gtk.Builder} UI definition.
2686
3247
  * {@link Gtk.Widget} stores the name as object data. Implement this method if your
2687
- * object has some notion of &#x201C;ID&#x201D; and it makes sense to map the XML id
3248
+ * object has some notion of ID and it makes sense to map the XML id
2688
3249
  * attribute to it.
2689
3250
  * @param id
2690
3251
  * @virtual
@@ -2926,6 +3487,11 @@ export namespace FoundryGtk {
2926
3487
  */
2927
3488
  type DiagnosticsGutterRendererClass = typeof DiagnosticsGutterRenderer;
2928
3489
 
3490
+ /**
3491
+ * @gir-type Alias
3492
+ */
3493
+ type GitLanesClass = typeof GitLanes;
3494
+
2929
3495
  /**
2930
3496
  * @gir-type Alias
2931
3497
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@girs/foundrygtk-1",
3
- "version": "4.2.0",
3
+ "version": "4.4.0",
4
4
  "description": "GJS TypeScript type definitions for FoundryGtk-1",
5
5
  "type": "module",
6
6
  "module": "foundrygtk-1.js",
@@ -36,26 +36,27 @@
36
36
  "test": "tsc --project tsconfig.json"
37
37
  },
38
38
  "dependencies": {
39
- "@girs/gjs": "^4.2.0",
40
- "@girs/peas-2": "^4.2.0",
41
- "@girs/gio-2.0": "^4.2.0",
42
- "@girs/gobject-2.0": "^4.2.0",
43
- "@girs/glib-2.0": "^4.2.0",
44
- "@girs/gmodule-2.0": "^4.2.0",
45
- "@girs/json-1.0": "^4.2.0",
46
- "@girs/gtksource-5": "^4.2.0",
47
- "@girs/gtk-4.0": "^4.2.0",
48
- "@girs/gsk-4.0": "^4.2.0",
49
- "@girs/graphene-1.0": "^4.2.0",
50
- "@girs/gdk-4.0": "^4.2.0",
51
- "@girs/cairo-1.0": "^4.2.0",
52
- "@girs/pangocairo-1.0": "^4.2.0",
53
- "@girs/pango-1.0": "^4.2.0",
54
- "@girs/harfbuzz-0.0": "^4.2.0",
55
- "@girs/freetype2-2.0": "^4.2.0",
56
- "@girs/gdkpixbuf-2.0": "^4.2.0",
57
- "@girs/foundry-1": "^4.2.0",
58
- "@girs/dex-1": "^4.2.0" },
39
+ "@girs/gjs": "^4.4.0",
40
+ "@girs/peas-2": "^4.4.0",
41
+ "@girs/gio-2.0": "^4.4.0",
42
+ "@girs/gobject-2.0": "^4.4.0",
43
+ "@girs/glib-2.0": "^4.4.0",
44
+ "@girs/gmodule-2.0": "^4.4.0",
45
+ "@girs/json-1.0": "^4.4.0",
46
+ "@girs/gtksource-5": "^4.4.0",
47
+ "@girs/gtk-4.0": "^4.4.0",
48
+ "@girs/gsk-4.0": "^4.4.0",
49
+ "@girs/graphene-1.0": "^4.4.0",
50
+ "@girs/gdk-4.0": "^4.4.0",
51
+ "@girs/cairo-1.0": "^4.4.0",
52
+ "@girs/pangocairo-1.0": "^4.4.0",
53
+ "@girs/pango-1.0": "^4.4.0",
54
+ "@girs/harfbuzz-0.0": "^4.4.0",
55
+ "@girs/freetype2-2.0": "^4.4.0",
56
+ "@girs/gdkpixbuf-2.0": "^4.4.0",
57
+ "@girs/foundry-1": "^4.4.0",
58
+ "@girs/dex-1": "^4.4.0",
59
+ "@girs/giounix-2.0": "^4.4.0" },
59
60
  "devDependencies": {
60
61
  "typescript": "*"
61
62
  },
package/tsconfig.json CHANGED
@@ -75,6 +75,9 @@
75
75
  "@girs/dex-1": [
76
76
  "../dex-1/index.d.ts"
77
77
  ],
78
+ "@girs/giounix-2.0": [
79
+ "../giounix-2.0/index.d.ts"
80
+ ],
78
81
  "@girs/gjs": [
79
82
  "../gjs/index.d.ts"
80
83
  ]