@girs/gtksource-5 5.1.0 → 5.2.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 +1 -1
- package/gtksource-5-vocabulary.d.ts +532 -12
- package/gtksource-5-vocabulary.js +127 -13
- package/package.json +16 -16
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|

|
|
5
5
|

|
|
6
6
|
|
|
7
|
-
GJS TypeScript type definitions for GtkSource-5, generated from library version 5.21.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v5.
|
|
7
|
+
GJS TypeScript type definitions for GtkSource-5, generated from library version 5.21.0 using [ts-for-gir](https://github.com/gjsify/ts-for-gir) v5.2.0.
|
|
8
8
|
|
|
9
9
|
This package contains type declarations only. It ships no runtime code, so it adds
|
|
10
10
|
nothing to your program and works with any bundler or none at all.
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The GIR-derived widget VOCABULARY for GtkSource-5.
|
|
3
3
|
*
|
|
4
|
-
* GENERATED — do not edit. Provenance: GtkSource-5 — library 5.21.0 — dropped empty base(s): GObject.
|
|
4
|
+
* GENERATED — do not edit. Provenance: GtkSource-5 — library 5.21.0 — dropped empty base(s): GObject.Object GObject.InitiallyUnowned Gio.ListModel
|
|
5
5
|
*
|
|
6
|
-
* 10 concrete widgets,
|
|
6
|
+
* 42 instantiable GTypes (of which 10 concrete widgets), 45 declarations, 13 enum nick unions, 2 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
|
|
@@ -24,13 +24,14 @@
|
|
|
24
24
|
* and the `notify::` keys folded in, is what `Widgets[G]['signals']` points at.
|
|
25
25
|
*/
|
|
26
26
|
|
|
27
|
+
import type GLib from '@girs/glib-2.0';
|
|
27
28
|
import type Gdk from '@girs/gdk-4.0';
|
|
28
29
|
import type GdkPixbuf from '@girs/gdkpixbuf-2.0';
|
|
29
30
|
import type Gio from '@girs/gio-2.0';
|
|
30
31
|
import type Gtk from '@girs/gtk-4.0';
|
|
31
32
|
import type GtkSource from './gtksource-5.js';
|
|
32
33
|
import type Pango from '@girs/pango-1.0';
|
|
33
|
-
import type { GtkAccessibleConstructOnly, GtkAccessibleProps, GtkAccessibleTextConstructOnly, GtkAccessibleTextProps, GtkActionableConstructOnly, GtkActionableProps, GtkBuildableConstructOnly, GtkBuildableProps, GtkButtonConstructOnly, GtkButtonProps, GtkConstraintTargetConstructOnly, GtkConstraintTargetProps, GtkScrollableConstructOnly, GtkScrollableProps, GtkTextViewConstructOnly, GtkTextViewProps, GtkTextWindowTypeNick, GtkWidgetConstructOnly, GtkWidgetProps } from '@girs/gtk-4.0/vocabulary';
|
|
34
|
+
import type { GtkAccessibleConstructOnly, GtkAccessibleProps, GtkAccessibleTextConstructOnly, GtkAccessibleTextProps, GtkActionableConstructOnly, GtkActionableProps, GtkBuildableConstructOnly, GtkBuildableProps, GtkButtonConstructOnly, GtkButtonProps, GtkConstraintTargetConstructOnly, GtkConstraintTargetProps, GtkIMContextConstructOnly, GtkIMContextProps, GtkScrollableConstructOnly, GtkScrollableProps, GtkTextBufferConstructOnly, GtkTextBufferProps, GtkTextMarkConstructOnly, GtkTextMarkProps, GtkTextTagConstructOnly, GtkTextTagProps, GtkTextViewConstructOnly, GtkTextViewProps, GtkTextWindowTypeNick, GtkWidgetConstructOnly, GtkWidgetProps, GtkWrapModeNick } from '@girs/gtk-4.0/vocabulary';
|
|
34
35
|
|
|
35
36
|
// ---------------------------------------------------------------------------
|
|
36
37
|
// Enum nicks — the string vocabulary GObject registered, from GIR's `glib:nick`.
|
|
@@ -53,6 +54,8 @@ export type GtkSourceGutterRendererAlignmentModeNick = 'cell' | 'first' | 'last'
|
|
|
53
54
|
export type GtkSourceNewlineTypeNick = 'lf' | 'cr' | 'cr-lf';
|
|
54
55
|
export type GtkSourceSmartHomeEndTypeNick = 'disabled' | 'before' | 'after' | 'always';
|
|
55
56
|
export type GtkSourceViewGutterPositionNick = 'lines' | 'marks';
|
|
57
|
+
export type PangoUnderlineNick = 'none' | 'single' | 'double' | 'low' | 'error' | 'single-line' | 'double-line' | 'error-line';
|
|
58
|
+
export type PangoWeightNick = 'thin' | 'ultralight' | 'light' | 'semilight' | 'book' | 'normal' | 'medium' | 'semibold' | 'bold' | 'ultrabold' | 'heavy' | 'ultraheavy';
|
|
56
59
|
|
|
57
60
|
// ---------------------------------------------------------------------------
|
|
58
61
|
// Property surfaces — one interface per GIR DECLARATION, mirroring GIR's own
|
|
@@ -64,6 +67,76 @@ export type GtkSourceViewGutterPositionNick = 'lines' | 'marks';
|
|
|
64
67
|
// GIR keeps them once, on the interface.
|
|
65
68
|
// ---------------------------------------------------------------------------
|
|
66
69
|
|
|
70
|
+
/** Represents an annotation added to [class@View], it has a [property@Annotation:line] property, [property@Annotation:description], icon and a style. */
|
|
71
|
+
export interface GtkSourceAnnotationProps {
|
|
72
|
+
}
|
|
73
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
74
|
+
export type GtkSourceAnnotationConstructOnly = never;
|
|
75
|
+
|
|
76
|
+
/** It is used to provide annotations and display them on [class@View] and also populate [class@HoverDisplay] when the user hovers over an annotation. */
|
|
77
|
+
export interface GtkSourceAnnotationProviderProps {
|
|
78
|
+
}
|
|
79
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
80
|
+
export type GtkSourceAnnotationProviderConstructOnly = never;
|
|
81
|
+
|
|
82
|
+
/** Use this object to manage [class@Annotation]s. */
|
|
83
|
+
export interface GtkSourceAnnotationsProps {
|
|
84
|
+
}
|
|
85
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
86
|
+
export type GtkSourceAnnotationsConstructOnly = never;
|
|
87
|
+
|
|
88
|
+
/** Subclass of [class@Gtk.TextBuffer]. */
|
|
89
|
+
export interface GtkSourceBufferProps extends GtkTextBufferProps {
|
|
90
|
+
/**
|
|
91
|
+
* Whether to highlight matching brackets in the buffer.
|
|
92
|
+
* @default TRUE
|
|
93
|
+
*/
|
|
94
|
+
'highlight-matching-brackets'?: boolean;
|
|
95
|
+
/**
|
|
96
|
+
* Whether to highlight syntax in the buffer.
|
|
97
|
+
* @default TRUE
|
|
98
|
+
*/
|
|
99
|
+
'highlight-syntax'?: boolean;
|
|
100
|
+
/**
|
|
101
|
+
* Whether the buffer has an implicit trailing newline.
|
|
102
|
+
* @default TRUE
|
|
103
|
+
*/
|
|
104
|
+
'implicit-trailing-newline'?: boolean;
|
|
105
|
+
language?: GtkSource.Language | null;
|
|
106
|
+
/** Style scheme. */
|
|
107
|
+
'style-scheme'?: GtkSource.StyleScheme | null;
|
|
108
|
+
}
|
|
109
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
110
|
+
export type GtkSourceBufferConstructOnly = GtkTextBufferConstructOnly;
|
|
111
|
+
|
|
112
|
+
/** Main Completion Object. */
|
|
113
|
+
export interface GtkSourceCompletionProps {
|
|
114
|
+
/**
|
|
115
|
+
* The number of rows to display to the user before scrolling.
|
|
116
|
+
* @default 5
|
|
117
|
+
*/
|
|
118
|
+
'page-size'?: number;
|
|
119
|
+
/**
|
|
120
|
+
* Determines whether the visibility of the info window should be saved when the completion is hidden, and restored when the completion is shown again.
|
|
121
|
+
* @default FALSE
|
|
122
|
+
*/
|
|
123
|
+
'remember-info-visibility'?: boolean;
|
|
124
|
+
/**
|
|
125
|
+
* Determines whether the first proposal should be selected when the completion is first shown.
|
|
126
|
+
* @default FALSE
|
|
127
|
+
*/
|
|
128
|
+
'select-on-show'?: boolean;
|
|
129
|
+
/**
|
|
130
|
+
* The "show-icons" property denotes if icons should be displayed within the list of completions presented to the user.
|
|
131
|
+
* @default TRUE
|
|
132
|
+
*/
|
|
133
|
+
'show-icons'?: boolean;
|
|
134
|
+
/** The "view" property is the #GtkTextView for which this #GtkSourceCompletion is providing completion features. */
|
|
135
|
+
view?: GtkSource.View;
|
|
136
|
+
}
|
|
137
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
138
|
+
export type GtkSourceCompletionConstructOnly = 'view';
|
|
139
|
+
|
|
67
140
|
/** Widget for single cell of completion proposal. */
|
|
68
141
|
export interface GtkSourceCompletionCellProps extends GtkWidgetProps, GtkAccessibleProps, GtkBuildableProps, GtkConstraintTargetProps {
|
|
69
142
|
/** @default GTK_SOURCE_COMPLETION_COLUMN_TYPED_TEXT */
|
|
@@ -78,6 +151,103 @@ export interface GtkSourceCompletionCellProps extends GtkWidgetProps, GtkAccessi
|
|
|
78
151
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
79
152
|
export type GtkSourceCompletionCellConstructOnly = GtkWidgetConstructOnly | GtkAccessibleConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly | 'column';
|
|
80
153
|
|
|
154
|
+
/** The context of a completion. */
|
|
155
|
+
export interface GtkSourceCompletionContextProps {
|
|
156
|
+
/** The "completion" is the #GtkSourceCompletion that was used to create the context. */
|
|
157
|
+
completion?: GtkSource.Completion | null;
|
|
158
|
+
}
|
|
159
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
160
|
+
export type GtkSourceCompletionContextConstructOnly = 'completion';
|
|
161
|
+
|
|
162
|
+
/** Completion provider interface. */
|
|
163
|
+
export interface GtkSourceCompletionProviderProps {
|
|
164
|
+
}
|
|
165
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
166
|
+
export type GtkSourceCompletionProviderConstructOnly = never;
|
|
167
|
+
|
|
168
|
+
/** A [iface@CompletionProvider] for the completion of snippets. */
|
|
169
|
+
export interface GtkSourceCompletionSnippetsProps extends GtkSourceCompletionProviderProps {
|
|
170
|
+
/** @default 0 */
|
|
171
|
+
priority?: number;
|
|
172
|
+
/** @default NULL */
|
|
173
|
+
title?: string;
|
|
174
|
+
}
|
|
175
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
176
|
+
export type GtkSourceCompletionSnippetsConstructOnly = GtkSourceCompletionProviderConstructOnly;
|
|
177
|
+
|
|
178
|
+
/** A [iface@CompletionProvider] for the completion of words. */
|
|
179
|
+
export interface GtkSourceCompletionWordsProps extends GtkSourceCompletionProviderProps {
|
|
180
|
+
/** @default 2 */
|
|
181
|
+
'minimum-word-size'?: number;
|
|
182
|
+
/** @default 0 */
|
|
183
|
+
priority?: number;
|
|
184
|
+
/** @default 300 */
|
|
185
|
+
'proposals-batch-size'?: number;
|
|
186
|
+
/** @default 50 */
|
|
187
|
+
'scan-batch-size'?: number;
|
|
188
|
+
/** @default NULL */
|
|
189
|
+
title?: string;
|
|
190
|
+
}
|
|
191
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
192
|
+
export type GtkSourceCompletionWordsConstructOnly = GtkSourceCompletionProviderConstructOnly;
|
|
193
|
+
|
|
194
|
+
/** On-disk representation of a [class@Buffer]. */
|
|
195
|
+
export interface GtkSourceFileProps {
|
|
196
|
+
/** The location. */
|
|
197
|
+
location?: Gio.File | null;
|
|
198
|
+
}
|
|
199
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
200
|
+
export type GtkSourceFileConstructOnly = never;
|
|
201
|
+
|
|
202
|
+
/** Load a file into a GtkSourceBuffer. */
|
|
203
|
+
export interface GtkSourceFileLoaderProps {
|
|
204
|
+
/** The #GtkSourceBuffer to load the contents into. */
|
|
205
|
+
buffer?: GtkSource.Buffer;
|
|
206
|
+
/** The #GtkSourceFile. */
|
|
207
|
+
file?: GtkSource.File;
|
|
208
|
+
/** The #GInputStream to load. */
|
|
209
|
+
'input-stream'?: Gio.InputStream | null;
|
|
210
|
+
/** The #GFile to load. */
|
|
211
|
+
location?: Gio.File | null;
|
|
212
|
+
/**
|
|
213
|
+
* The maximum expanded size, in bytes, that the loader will insert into the buffer.
|
|
214
|
+
* @since 5.22
|
|
215
|
+
* @default 1073741824
|
|
216
|
+
*/
|
|
217
|
+
'max-size'?: bigint | number;
|
|
218
|
+
}
|
|
219
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
220
|
+
export type GtkSourceFileLoaderConstructOnly = 'buffer' | 'file' | 'input-stream' | 'location';
|
|
221
|
+
|
|
222
|
+
/** Save a [class@Buffer] into a file. */
|
|
223
|
+
export interface GtkSourceFileSaverProps {
|
|
224
|
+
/** The #GtkSourceBuffer to save. */
|
|
225
|
+
buffer?: GtkSource.Buffer;
|
|
226
|
+
/**
|
|
227
|
+
* The compression type.
|
|
228
|
+
* @default GTK_SOURCE_COMPRESSION_TYPE_NONE
|
|
229
|
+
*/
|
|
230
|
+
'compression-type'?: GtkSourceCompressionTypeNick | GtkSource.CompressionType;
|
|
231
|
+
/** The file's encoding. */
|
|
232
|
+
encoding?: GtkSource.Encoding;
|
|
233
|
+
/** The #GtkSourceFile. */
|
|
234
|
+
file?: GtkSource.File;
|
|
235
|
+
/**
|
|
236
|
+
* File saving flags.
|
|
237
|
+
* @default GTK_SOURCE_FILE_SAVER_FLAGS_NONE
|
|
238
|
+
*/
|
|
239
|
+
flags?: number;
|
|
240
|
+
/** The #GFile where to save the buffer. */
|
|
241
|
+
location?: Gio.File;
|
|
242
|
+
/**
|
|
243
|
+
* The newline type.
|
|
244
|
+
* @default GTK_SOURCE_NEWLINE_TYPE_LF
|
|
245
|
+
*/
|
|
246
|
+
'newline-type'?: GtkSourceNewlineTypeNick | GtkSource.NewlineType;
|
|
247
|
+
}
|
|
248
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
249
|
+
export type GtkSourceFileSaverConstructOnly = 'buffer' | 'file' | 'location';
|
|
250
|
+
|
|
81
251
|
/** Gutter object for [class@View]. */
|
|
82
252
|
export interface GtkSourceGutterProps extends GtkWidgetProps, GtkAccessibleProps, GtkBuildableProps, GtkConstraintTargetProps {
|
|
83
253
|
/** The #GtkSourceView of the gutter. */
|
|
@@ -91,6 +261,12 @@ export interface GtkSourceGutterProps extends GtkWidgetProps, GtkAccessibleProps
|
|
|
91
261
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
92
262
|
export type GtkSourceGutterConstructOnly = GtkWidgetConstructOnly | GtkAccessibleConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly | 'view' | 'window-type';
|
|
93
263
|
|
|
264
|
+
/** Collected information about visible lines. */
|
|
265
|
+
export interface GtkSourceGutterLinesProps {
|
|
266
|
+
}
|
|
267
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
268
|
+
export type GtkSourceGutterLinesConstructOnly = never;
|
|
269
|
+
|
|
94
270
|
/** Gutter cell renderer. */
|
|
95
271
|
export interface GtkSourceGutterRendererProps extends GtkWidgetProps, GtkAccessibleProps, GtkBuildableProps, GtkConstraintTargetProps {
|
|
96
272
|
/**
|
|
@@ -143,12 +319,42 @@ export interface GtkSourceGutterRendererTextProps extends GtkSourceGutterRendere
|
|
|
143
319
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
144
320
|
export type GtkSourceGutterRendererTextConstructOnly = GtkSourceGutterRendererConstructOnly | GtkAccessibleConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly;
|
|
145
321
|
|
|
322
|
+
/** Interactive tooltips. */
|
|
323
|
+
export interface GtkSourceHoverProps {
|
|
324
|
+
/**
|
|
325
|
+
* Contains the number of milliseconds to delay before showing the hover assistant.
|
|
326
|
+
* @default 500
|
|
327
|
+
*/
|
|
328
|
+
'hover-delay'?: number;
|
|
329
|
+
}
|
|
330
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
331
|
+
export type GtkSourceHoverConstructOnly = never;
|
|
332
|
+
|
|
333
|
+
/** Context for populating [class@HoverDisplay] contents. */
|
|
334
|
+
export interface GtkSourceHoverContextProps {
|
|
335
|
+
}
|
|
336
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
337
|
+
export type GtkSourceHoverContextConstructOnly = never;
|
|
338
|
+
|
|
146
339
|
/** Display for interactive tooltips. */
|
|
147
340
|
export interface GtkSourceHoverDisplayProps extends GtkWidgetProps, GtkAccessibleProps, GtkBuildableProps, GtkConstraintTargetProps {
|
|
148
341
|
}
|
|
149
342
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
150
343
|
export type GtkSourceHoverDisplayConstructOnly = GtkWidgetConstructOnly | GtkAccessibleConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly;
|
|
151
344
|
|
|
345
|
+
/** Represents a syntax highlighted language. */
|
|
346
|
+
export interface GtkSourceLanguageProps {
|
|
347
|
+
}
|
|
348
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
349
|
+
export type GtkSourceLanguageConstructOnly = never;
|
|
350
|
+
|
|
351
|
+
/** Provides access to [class@Language]s. */
|
|
352
|
+
export interface GtkSourceLanguageManagerProps {
|
|
353
|
+
'search-path'?: string[];
|
|
354
|
+
}
|
|
355
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
356
|
+
export type GtkSourceLanguageManagerConstructOnly = never;
|
|
357
|
+
|
|
152
358
|
/** Widget that displays a map for a specific [class@View]. */
|
|
153
359
|
export interface GtkSourceMapProps extends GtkSourceViewProps, GtkAccessibleProps, GtkAccessibleTextProps, GtkBuildableProps, GtkConstraintTargetProps, GtkScrollableProps {
|
|
154
360
|
'font-desc'?: Pango.FontDescription;
|
|
@@ -157,6 +363,269 @@ export interface GtkSourceMapProps extends GtkSourceViewProps, GtkAccessibleProp
|
|
|
157
363
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
158
364
|
export type GtkSourceMapConstructOnly = GtkSourceViewConstructOnly | GtkAccessibleConstructOnly | GtkAccessibleTextConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly | GtkScrollableConstructOnly;
|
|
159
365
|
|
|
366
|
+
/** Mark object for [class@Buffer]. */
|
|
367
|
+
export interface GtkSourceMarkProps extends GtkTextMarkProps {
|
|
368
|
+
/**
|
|
369
|
+
* The category of the `GtkSourceMark`, classifies the mark and controls which pixbuf is used and with which priority it is drawn.
|
|
370
|
+
* @default NULL
|
|
371
|
+
*/
|
|
372
|
+
category?: string;
|
|
373
|
+
}
|
|
374
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
375
|
+
export type GtkSourceMarkConstructOnly = GtkTextMarkConstructOnly | 'category';
|
|
376
|
+
|
|
377
|
+
/** The source mark attributes object. */
|
|
378
|
+
export interface GtkSourceMarkAttributesProps {
|
|
379
|
+
/** A color used for background of a line. */
|
|
380
|
+
background?: Gdk.RGBA;
|
|
381
|
+
/** A #GIcon that may be a base of a rendered icon. */
|
|
382
|
+
gicon?: Gio.Icon;
|
|
383
|
+
/**
|
|
384
|
+
* An icon name that may be a base of a rendered icon.
|
|
385
|
+
* @default NULL
|
|
386
|
+
*/
|
|
387
|
+
'icon-name'?: string;
|
|
388
|
+
/** A #GdkPixbuf that may be a base of a rendered icon. */
|
|
389
|
+
pixbuf?: GdkPixbuf.Pixbuf;
|
|
390
|
+
}
|
|
391
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
392
|
+
export type GtkSourceMarkAttributesConstructOnly = never;
|
|
393
|
+
|
|
394
|
+
/** Compose a [class@Buffer] for printing. */
|
|
395
|
+
export interface GtkSourcePrintCompositorProps {
|
|
396
|
+
/**
|
|
397
|
+
* Name of the font used for the text body.
|
|
398
|
+
* @default NULL
|
|
399
|
+
*/
|
|
400
|
+
'body-font-name'?: string;
|
|
401
|
+
/** The [class@Buffer] object to print. */
|
|
402
|
+
buffer?: GtkSource.Buffer;
|
|
403
|
+
/**
|
|
404
|
+
* Name of the font used to print page footer.
|
|
405
|
+
* @default NULL
|
|
406
|
+
*/
|
|
407
|
+
'footer-font-name'?: string;
|
|
408
|
+
/**
|
|
409
|
+
* Name of the font used to print page header.
|
|
410
|
+
* @default NULL
|
|
411
|
+
*/
|
|
412
|
+
'header-font-name'?: string;
|
|
413
|
+
/**
|
|
414
|
+
* Whether to print the document with highlighted syntax.
|
|
415
|
+
* @default TRUE
|
|
416
|
+
*/
|
|
417
|
+
'highlight-syntax'?: boolean;
|
|
418
|
+
/**
|
|
419
|
+
* Name of the font used to print line numbers on the left margin.
|
|
420
|
+
* @default NULL
|
|
421
|
+
*/
|
|
422
|
+
'line-numbers-font-name'?: string;
|
|
423
|
+
/**
|
|
424
|
+
* Whether to print a footer in each page.
|
|
425
|
+
* @default FALSE
|
|
426
|
+
*/
|
|
427
|
+
'print-footer'?: boolean;
|
|
428
|
+
/**
|
|
429
|
+
* Whether to print a header in each page.
|
|
430
|
+
* @default FALSE
|
|
431
|
+
*/
|
|
432
|
+
'print-header'?: boolean;
|
|
433
|
+
/**
|
|
434
|
+
* Interval of printed line numbers.
|
|
435
|
+
* @default 1
|
|
436
|
+
*/
|
|
437
|
+
'print-line-numbers'?: number;
|
|
438
|
+
/**
|
|
439
|
+
* Width of a tab character expressed in spaces.
|
|
440
|
+
* @default 8
|
|
441
|
+
*/
|
|
442
|
+
'tab-width'?: number;
|
|
443
|
+
/**
|
|
444
|
+
* Whether to wrap lines never, at word boundaries, or at character boundaries.
|
|
445
|
+
* @default GTK_WRAP_NONE
|
|
446
|
+
*/
|
|
447
|
+
'wrap-mode'?: GtkWrapModeNick | Gtk.WrapMode;
|
|
448
|
+
}
|
|
449
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
450
|
+
export type GtkSourcePrintCompositorConstructOnly = 'buffer';
|
|
451
|
+
|
|
452
|
+
/** Region utility. */
|
|
453
|
+
export interface GtkSourceRegionProps {
|
|
454
|
+
/** The [class@Gtk.TextBuffer]. */
|
|
455
|
+
buffer?: Gtk.TextBuffer | null;
|
|
456
|
+
}
|
|
457
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
458
|
+
export type GtkSourceRegionConstructOnly = 'buffer';
|
|
459
|
+
|
|
460
|
+
/** Search context. */
|
|
461
|
+
export interface GtkSourceSearchContextProps {
|
|
462
|
+
/** The [class@Buffer] associated to the search context. */
|
|
463
|
+
buffer?: GtkSource.Buffer;
|
|
464
|
+
/**
|
|
465
|
+
* Highlight the search occurrences.
|
|
466
|
+
* @default TRUE
|
|
467
|
+
*/
|
|
468
|
+
highlight?: boolean;
|
|
469
|
+
/** A [class@Style], or %NULL for theme's scheme default style. */
|
|
470
|
+
'match-style'?: GtkSource.Style | null;
|
|
471
|
+
/** The [class@SearchSettings] associated to the search context. */
|
|
472
|
+
settings?: GtkSource.SearchSettings;
|
|
473
|
+
}
|
|
474
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
475
|
+
export type GtkSourceSearchContextConstructOnly = 'buffer' | 'settings';
|
|
476
|
+
|
|
477
|
+
/** Search settings. */
|
|
478
|
+
export interface GtkSourceSearchSettingsProps {
|
|
479
|
+
/**
|
|
480
|
+
* If %TRUE, a search match must start and end a word.
|
|
481
|
+
* @default FALSE
|
|
482
|
+
*/
|
|
483
|
+
'at-word-boundaries'?: boolean;
|
|
484
|
+
/**
|
|
485
|
+
* Whether the search is case sensitive.
|
|
486
|
+
* @default FALSE
|
|
487
|
+
*/
|
|
488
|
+
'case-sensitive'?: boolean;
|
|
489
|
+
/**
|
|
490
|
+
* Search by regular expressions with [property@SearchSettings:search-text] as the pattern.
|
|
491
|
+
* @default FALSE
|
|
492
|
+
*/
|
|
493
|
+
'regex-enabled'?: boolean;
|
|
494
|
+
/**
|
|
495
|
+
* A search string, or %NULL if the search is disabled.
|
|
496
|
+
* @default NULL
|
|
497
|
+
*/
|
|
498
|
+
'search-text'?: string | null;
|
|
499
|
+
/**
|
|
500
|
+
* Exclude invisible text from the search.
|
|
501
|
+
* @since 5.12
|
|
502
|
+
* @default TRUE
|
|
503
|
+
*/
|
|
504
|
+
'visible-only'?: boolean;
|
|
505
|
+
/**
|
|
506
|
+
* For a forward search, continue at the beginning of the buffer if no search occurrence is found.
|
|
507
|
+
* @default FALSE
|
|
508
|
+
*/
|
|
509
|
+
'wrap-around'?: boolean;
|
|
510
|
+
}
|
|
511
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
512
|
+
export type GtkSourceSearchSettingsConstructOnly = never;
|
|
513
|
+
|
|
514
|
+
/** Quick insertion code snippets. */
|
|
515
|
+
export interface GtkSourceSnippetProps {
|
|
516
|
+
/** @default NULL */
|
|
517
|
+
description?: string;
|
|
518
|
+
/** @default NULL */
|
|
519
|
+
'language-id'?: string;
|
|
520
|
+
/** @default NULL */
|
|
521
|
+
name?: string;
|
|
522
|
+
/** @default NULL */
|
|
523
|
+
trigger?: string | null;
|
|
524
|
+
}
|
|
525
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
526
|
+
export type GtkSourceSnippetConstructOnly = never;
|
|
527
|
+
|
|
528
|
+
/** A chunk of text within the source snippet. */
|
|
529
|
+
export interface GtkSourceSnippetChunkProps {
|
|
530
|
+
context?: GtkSource.SnippetContext;
|
|
531
|
+
/** @default -1 */
|
|
532
|
+
'focus-position'?: number;
|
|
533
|
+
/** @default NULL */
|
|
534
|
+
spec?: string | null;
|
|
535
|
+
/** @default NULL */
|
|
536
|
+
text?: string;
|
|
537
|
+
/** @default FALSE */
|
|
538
|
+
'text-set'?: boolean;
|
|
539
|
+
/** @default NULL */
|
|
540
|
+
'tooltip-text'?: string;
|
|
541
|
+
}
|
|
542
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
543
|
+
export type GtkSourceSnippetChunkConstructOnly = never;
|
|
544
|
+
|
|
545
|
+
/** Context for expanding [class@SnippetChunk]. */
|
|
546
|
+
export interface GtkSourceSnippetContextProps {
|
|
547
|
+
}
|
|
548
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
549
|
+
export type GtkSourceSnippetContextConstructOnly = never;
|
|
550
|
+
|
|
551
|
+
/** Provides access to [class@Snippet]. */
|
|
552
|
+
export interface GtkSourceSnippetManagerProps {
|
|
553
|
+
/** Contains a list of directories to search for files containing snippets (*.snippets). */
|
|
554
|
+
'search-path'?: string[];
|
|
555
|
+
}
|
|
556
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
557
|
+
export type GtkSourceSnippetManagerConstructOnly = never;
|
|
558
|
+
|
|
559
|
+
/** Represent white space characters with symbols. */
|
|
560
|
+
export interface GtkSourceSpaceDrawerProps {
|
|
561
|
+
/**
|
|
562
|
+
* Whether the [property@SpaceDrawer:matrix] property is enabled.
|
|
563
|
+
* @default FALSE
|
|
564
|
+
*/
|
|
565
|
+
'enable-matrix'?: boolean;
|
|
566
|
+
/** The property is a [struct@GLib.Variant] property to specify where and what kind of white spaces to draw. */
|
|
567
|
+
matrix?: GLib.Variant;
|
|
568
|
+
}
|
|
569
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
570
|
+
export type GtkSourceSpaceDrawerConstructOnly = never;
|
|
571
|
+
|
|
572
|
+
/** Represents a style. */
|
|
573
|
+
export interface GtkSourceStyleProps {
|
|
574
|
+
/** @default NULL */
|
|
575
|
+
background?: string;
|
|
576
|
+
/** @default FALSE */
|
|
577
|
+
'background-set'?: boolean;
|
|
578
|
+
/** @default FALSE */
|
|
579
|
+
bold?: boolean;
|
|
580
|
+
/** @default FALSE */
|
|
581
|
+
'bold-set'?: boolean;
|
|
582
|
+
/** @default NULL */
|
|
583
|
+
foreground?: string;
|
|
584
|
+
/** @default FALSE */
|
|
585
|
+
'foreground-set'?: boolean;
|
|
586
|
+
/** @default FALSE */
|
|
587
|
+
italic?: boolean;
|
|
588
|
+
/** @default FALSE */
|
|
589
|
+
'italic-set'?: boolean;
|
|
590
|
+
/** @default NULL */
|
|
591
|
+
'line-background'?: string;
|
|
592
|
+
/** @default FALSE */
|
|
593
|
+
'line-background-set'?: boolean;
|
|
594
|
+
/** @default PANGO_UNDERLINE_NONE */
|
|
595
|
+
'pango-underline'?: PangoUnderlineNick | Pango.Underline;
|
|
596
|
+
/** @default NULL */
|
|
597
|
+
scale?: string;
|
|
598
|
+
/** @default FALSE */
|
|
599
|
+
'scale-set'?: boolean;
|
|
600
|
+
/** @default FALSE */
|
|
601
|
+
strikethrough?: boolean;
|
|
602
|
+
/** @default FALSE */
|
|
603
|
+
'strikethrough-set'?: boolean;
|
|
604
|
+
/** @default NULL */
|
|
605
|
+
'underline-color'?: string;
|
|
606
|
+
/** @default FALSE */
|
|
607
|
+
'underline-color-set'?: boolean;
|
|
608
|
+
/** @default FALSE */
|
|
609
|
+
'underline-set'?: boolean;
|
|
610
|
+
/** @default PANGO_WEIGHT_NORMAL */
|
|
611
|
+
weight?: PangoWeightNick | Pango.Weight;
|
|
612
|
+
/** @default FALSE */
|
|
613
|
+
'weight-set'?: boolean;
|
|
614
|
+
}
|
|
615
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
616
|
+
export type GtkSourceStyleConstructOnly = 'background' | 'background-set' | 'bold' | 'bold-set' | 'foreground' | 'foreground-set' | 'italic' | 'italic-set' | 'line-background' | 'line-background-set' | 'pango-underline' | 'scale' | 'scale-set' | 'strikethrough' | 'strikethrough-set' | 'underline-color' | 'underline-color-set' | 'underline-set' | 'weight' | 'weight-set';
|
|
617
|
+
|
|
618
|
+
/** Controls the appearance of [class@View]. */
|
|
619
|
+
export interface GtkSourceStyleSchemeProps {
|
|
620
|
+
/**
|
|
621
|
+
* Style scheme id, a unique string used to identify the style scheme in [class@StyleSchemeManager].
|
|
622
|
+
* @default NULL
|
|
623
|
+
*/
|
|
624
|
+
id?: string;
|
|
625
|
+
}
|
|
626
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
627
|
+
export type GtkSourceStyleSchemeConstructOnly = 'id';
|
|
628
|
+
|
|
160
629
|
/** Interface implemented by widgets for choosing style schemes. */
|
|
161
630
|
export interface GtkSourceStyleSchemeChooserProps {
|
|
162
631
|
/** Contains the currently selected style scheme. */
|
|
@@ -177,6 +646,13 @@ export interface GtkSourceStyleSchemeChooserWidgetProps extends GtkWidgetProps,
|
|
|
177
646
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
178
647
|
export type GtkSourceStyleSchemeChooserWidgetConstructOnly = GtkWidgetConstructOnly | GtkAccessibleConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly | GtkSourceStyleSchemeChooserConstructOnly;
|
|
179
648
|
|
|
649
|
+
/** Provides access to [class@StyleScheme]s. */
|
|
650
|
+
export interface GtkSourceStyleSchemeManagerProps {
|
|
651
|
+
'search-path'?: string[];
|
|
652
|
+
}
|
|
653
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
654
|
+
export type GtkSourceStyleSchemeManagerConstructOnly = never;
|
|
655
|
+
|
|
180
656
|
/** A preview widget for [class@StyleScheme]. */
|
|
181
657
|
export interface GtkSourceStyleSchemePreviewProps extends GtkWidgetProps, GtkAccessibleProps, GtkActionableProps, GtkBuildableProps, GtkConstraintTargetProps {
|
|
182
658
|
scheme?: GtkSource.StyleScheme;
|
|
@@ -186,6 +662,22 @@ export interface GtkSourceStyleSchemePreviewProps extends GtkWidgetProps, GtkAcc
|
|
|
186
662
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
187
663
|
export type GtkSourceStyleSchemePreviewConstructOnly = GtkWidgetConstructOnly | GtkAccessibleConstructOnly | GtkActionableConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly | 'scheme';
|
|
188
664
|
|
|
665
|
+
/** A tag that can be applied to text in a [class@Buffer]. */
|
|
666
|
+
export interface GtkSourceTagProps extends GtkTextTagProps {
|
|
667
|
+
/**
|
|
668
|
+
* Whether to draw white spaces.
|
|
669
|
+
* @default FALSE
|
|
670
|
+
*/
|
|
671
|
+
'draw-spaces'?: boolean;
|
|
672
|
+
/**
|
|
673
|
+
* Whether the [property@Tag:draw-spaces] property is set and must be taken into account.
|
|
674
|
+
* @default FALSE
|
|
675
|
+
*/
|
|
676
|
+
'draw-spaces-set'?: boolean;
|
|
677
|
+
}
|
|
678
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
679
|
+
export type GtkSourceTagConstructOnly = GtkTextTagConstructOnly;
|
|
680
|
+
|
|
189
681
|
/** Subclass of [class@Gtk.TextView]. */
|
|
190
682
|
export interface GtkSourceViewProps extends GtkTextViewProps, GtkAccessibleProps, GtkAccessibleTextProps, GtkBuildableProps, GtkConstraintTargetProps, GtkScrollableProps {
|
|
191
683
|
/** @default FALSE */
|
|
@@ -252,6 +744,12 @@ export interface GtkSourceViewProps extends GtkTextViewProps, GtkAccessibleProps
|
|
|
252
744
|
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
253
745
|
export type GtkSourceViewConstructOnly = GtkTextViewConstructOnly | GtkAccessibleConstructOnly | GtkAccessibleTextConstructOnly | GtkBuildableConstructOnly | GtkConstraintTargetConstructOnly | GtkScrollableConstructOnly;
|
|
254
746
|
|
|
747
|
+
/** Vim emulation. */
|
|
748
|
+
export interface GtkSourceVimIMContextProps extends GtkIMContextProps {
|
|
749
|
+
}
|
|
750
|
+
/** Settable only at construction — a renderer must REBUILD, not patch. */
|
|
751
|
+
export type GtkSourceVimIMContextConstructOnly = GtkIMContextConstructOnly;
|
|
752
|
+
|
|
255
753
|
// ---------------------------------------------------------------------------
|
|
256
754
|
// The GType-keyed widget map.
|
|
257
755
|
//
|
|
@@ -344,7 +842,11 @@ export interface Widgets {
|
|
|
344
842
|
};
|
|
345
843
|
}
|
|
346
844
|
|
|
347
|
-
/**
|
|
845
|
+
/**
|
|
846
|
+
* Every GType this namespace can create AND put on screen. A consumer derives its own
|
|
847
|
+
* tag map. For everything a UI file can instantiate — layout managers, event
|
|
848
|
+
* controllers, cell renderers, `GtkSizeGroup` — read `DECLS` below.
|
|
849
|
+
*/
|
|
348
850
|
export type WidgetGType = keyof Widgets;
|
|
349
851
|
|
|
350
852
|
// ---------------------------------------------------------------------------
|
|
@@ -396,7 +898,14 @@ export const PROVENANCE: {
|
|
|
396
898
|
readonly childHolders: number;
|
|
397
899
|
readonly droppedBases: readonly string[];
|
|
398
900
|
readonly inlinedBases: readonly string[];
|
|
901
|
+
/** `<decl>.<prop>` for every property printed `never` because TypeScript has no value for it. */
|
|
399
902
|
readonly unsettableProps: readonly string[];
|
|
903
|
+
/**
|
|
904
|
+
* `<decl>.<prop>: <Ns>.<Name>` for every property printed `never` because the model
|
|
905
|
+
* could not resolve its type across a namespace boundary — two independently released
|
|
906
|
+
* GIRs disagreeing, which is what the main emitter answers `never` for as well.
|
|
907
|
+
*/
|
|
908
|
+
readonly unresolvedProps: readonly string[];
|
|
400
909
|
};
|
|
401
910
|
|
|
402
911
|
/** Declaration GType -> its own settable properties, as GObject registered them. */
|
|
@@ -410,7 +919,17 @@ export const OWN_PROPS: Readonly<Record<string, readonly string[]>>;
|
|
|
410
919
|
*/
|
|
411
920
|
export const OWN_SIGNALS: Readonly<Record<string, readonly string[]>>;
|
|
412
921
|
|
|
413
|
-
/**
|
|
922
|
+
/**
|
|
923
|
+
* Instantiable GType -> every declaration its members come from, self first.
|
|
924
|
+
*
|
|
925
|
+
* The key set is what a UI description file can NAME: every registered, non-abstract
|
|
926
|
+
* class this namespace declares. GtkBuilder resolves a `<object class="…">` through
|
|
927
|
+
* `g_type_from_name`, which knows nothing about widgets, so this is wider than
|
|
928
|
+
* `Widgets` by design — `GtkSizeGroup`, `GtkTextTag`, every `GtkEventController`
|
|
929
|
+
* and every `GtkCellRenderer` are here and are not widgets.
|
|
930
|
+
*
|
|
931
|
+
* `Widgets` and `CHILD_HOLDERS` are the narrower questions and answer them unchanged.
|
|
932
|
+
*/
|
|
414
933
|
export const DECLS: Readonly<Record<string, readonly string[]>>;
|
|
415
934
|
|
|
416
935
|
/** The GTypes in `DECLS` that hold a widget without being one — see `ChildHolders`. */
|
|
@@ -422,8 +941,8 @@ export const ENUM_NICKS: Readonly<Record<string, readonly string[]>>;
|
|
|
422
941
|
/**
|
|
423
942
|
* `<enum GType>.<nick>` -> the integer GObject registers for it, from GIR's `value`.
|
|
424
943
|
*
|
|
425
|
-
* Position in `ENUM_NICKS` is NOT this number. Counting is wrong on 6 of the
|
|
426
|
-
* GTK 4 vocabulary carries --
|
|
944
|
+
* Position in `ENUM_NICKS` is NOT this number. Counting is wrong on 6 of the 137 enums a
|
|
945
|
+
* GTK 4 vocabulary carries -- 112 in Gtk-4.0 and 25 in Adw-1: `GtkResponseType` runs -1 to -11, `GtkTextWindowType` starts
|
|
427
946
|
* at 1, `GtkOrdering` and `GtkConstraintRelation` are -1/0/1, `GtkAlign` has two names
|
|
428
947
|
* on one value, and `GtkConstraintStrength.required` is 1001001000 where counting says 0.
|
|
429
948
|
*
|
|
@@ -461,10 +980,11 @@ export const ENUM_VALUES_UNREADABLE: Readonly<Record<string, string>>;
|
|
|
461
980
|
*
|
|
462
981
|
* `ENUM_NICKS` carries no bitfield, because GObject cannot resolve a nick SET; that says
|
|
463
982
|
* nothing about a single member's number, and the number is what a host without GI needs.
|
|
464
|
-
*
|
|
465
|
-
*
|
|
466
|
-
* among them. Counting is worst here:
|
|
467
|
-
*
|
|
983
|
+
* 23 settable properties in Gtk-4.0 and Adw-1 are bitfield-typed and are declared bare
|
|
984
|
+
* `number` -- `GtkEntry:input-hints`, `GtkPopoverMenu:flags`, `AdwTabView:shortcuts`,
|
|
985
|
+
* `GtkDropTarget:actions` among them. Counting is worst here: 119 of the 156 Gtk-4.0
|
|
986
|
+
* bitfield members this vocabulary carries disagree with their declaration position,
|
|
987
|
+
* against 29 of 672 enumeration members.
|
|
468
988
|
*
|
|
469
989
|
* Combine with `|` as GObject does. There is no nick table to pair this with, so a name
|
|
470
990
|
* here is resolvable and a SET still is not.
|
|
@@ -488,7 +1008,7 @@ export const FLAG_VALUES_UNREADABLE: Readonly<Record<string, string>>;
|
|
|
488
1008
|
*
|
|
489
1009
|
* The GType named here is not always one THIS module gives numbers for. A nick vocabulary is
|
|
490
1010
|
* emitted once, by the namespace that owns the enum, so `AdwComboRow.search-match-mode` names
|
|
491
|
-
* `GtkStringFilterMatchMode` and its rows are in `@girs/gtk-4.0/vocabulary` —
|
|
1011
|
+
* `GtkStringFilterMatchMode` and its rows are in `@girs/gtk-4.0/vocabulary` — 83 of the 909
|
|
492
1012
|
* entries in a full run resolve only with the owner's vocabulary loaded beside this one. An
|
|
493
1013
|
* owner with no vocabulary of its own (Gdk, Pango) is inlined here instead, so every entry
|
|
494
1014
|
* resolves against SOME module.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// The widget vocabulary of GtkSource-5 as runtime data.
|
|
2
2
|
//
|
|
3
|
-
// GENERATED — do not edit. Provenance: GtkSource-5 — library 5.21.0 — dropped empty base(s): GObject.
|
|
3
|
+
// GENERATED — do not edit. Provenance: GtkSource-5 — library 5.21.0 — dropped empty base(s): GObject.Object GObject.InitiallyUnowned Gio.ListModel
|
|
4
4
|
//
|
|
5
5
|
// The type half of this subpath is the sibling `.d.ts`. This file exists because
|
|
6
6
|
// types are erased: a consumer that wants to ask the installed library whether every
|
|
@@ -11,46 +11,119 @@ export const PROVENANCE = {
|
|
|
11
11
|
version: '5',
|
|
12
12
|
libraryVersion: '5.21.0',
|
|
13
13
|
childHolders: 0,
|
|
14
|
-
droppedBases: ['GObject.
|
|
14
|
+
droppedBases: ['GObject.Object', 'GObject.InitiallyUnowned', 'Gio.ListModel'],
|
|
15
15
|
inlinedBases: [],
|
|
16
16
|
unsettableProps: [],
|
|
17
|
+
unresolvedProps: [],
|
|
17
18
|
};
|
|
18
19
|
|
|
19
20
|
export const OWN_PROPS = {
|
|
21
|
+
GtkSourceBuffer: ['highlight-matching-brackets', 'highlight-syntax', 'implicit-trailing-newline', 'language', 'style-scheme'],
|
|
22
|
+
GtkSourceCompletion: ['page-size', 'remember-info-visibility', 'select-on-show', 'show-icons', 'view'],
|
|
20
23
|
GtkSourceCompletionCell: ['column', 'markup', 'paintable', 'text', 'widget'],
|
|
24
|
+
GtkSourceCompletionContext: ['completion'],
|
|
25
|
+
GtkSourceCompletionSnippets: ['priority', 'title'],
|
|
26
|
+
GtkSourceCompletionWords: ['minimum-word-size', 'priority', 'proposals-batch-size', 'scan-batch-size', 'title'],
|
|
27
|
+
GtkSourceFile: ['location'],
|
|
28
|
+
GtkSourceFileLoader: ['buffer', 'file', 'input-stream', 'location', 'max-size'],
|
|
29
|
+
GtkSourceFileSaver: ['buffer', 'compression-type', 'encoding', 'file', 'flags', 'location', 'newline-type'],
|
|
21
30
|
GtkSourceGutter: ['view', 'window-type'],
|
|
22
31
|
GtkSourceGutterRenderer: ['alignment-mode', 'xalign', 'xpad', 'yalign', 'ypad'],
|
|
23
32
|
GtkSourceGutterRendererPixbuf: ['gicon', 'icon-name', 'paintable', 'pixbuf'],
|
|
24
33
|
GtkSourceGutterRendererText: ['markup', 'text'],
|
|
34
|
+
GtkSourceHover: ['hover-delay'],
|
|
35
|
+
GtkSourceLanguageManager: ['search-path'],
|
|
25
36
|
GtkSourceMap: ['font-desc', 'view'],
|
|
37
|
+
GtkSourceMark: ['category'],
|
|
38
|
+
GtkSourceMarkAttributes: ['background', 'gicon', 'icon-name', 'pixbuf'],
|
|
39
|
+
GtkSourcePrintCompositor: ['body-font-name', 'buffer', 'footer-font-name', 'header-font-name', 'highlight-syntax', 'line-numbers-font-name', 'print-footer', 'print-header', 'print-line-numbers', 'tab-width', 'wrap-mode'],
|
|
40
|
+
GtkSourceRegion: ['buffer'],
|
|
41
|
+
GtkSourceSearchContext: ['buffer', 'highlight', 'match-style', 'settings'],
|
|
42
|
+
GtkSourceSearchSettings: ['at-word-boundaries', 'case-sensitive', 'regex-enabled', 'search-text', 'visible-only', 'wrap-around'],
|
|
43
|
+
GtkSourceSnippet: ['description', 'language-id', 'name', 'trigger'],
|
|
44
|
+
GtkSourceSnippetChunk: ['context', 'focus-position', 'spec', 'text', 'text-set', 'tooltip-text'],
|
|
45
|
+
GtkSourceSnippetManager: ['search-path'],
|
|
46
|
+
GtkSourceSpaceDrawer: ['enable-matrix', 'matrix'],
|
|
47
|
+
GtkSourceStyle: ['background', 'background-set', 'bold', 'bold-set', 'foreground', 'foreground-set', 'italic', 'italic-set', 'line-background', 'line-background-set', 'pango-underline', 'scale', 'scale-set', 'strikethrough', 'strikethrough-set', 'underline-color', 'underline-color-set', 'underline-set', 'weight', 'weight-set'],
|
|
48
|
+
GtkSourceStyleScheme: ['id'],
|
|
26
49
|
GtkSourceStyleSchemeChooser: ['style-scheme'],
|
|
50
|
+
GtkSourceStyleSchemeManager: ['search-path'],
|
|
27
51
|
GtkSourceStyleSchemePreview: ['scheme', 'selected'],
|
|
52
|
+
GtkSourceTag: ['draw-spaces', 'draw-spaces-set'],
|
|
28
53
|
GtkSourceView: ['auto-indent', 'background-pattern', 'enable-snippets', 'highlight-current-line', 'indent-on-tab', 'indent-width', 'indenter', 'insert-spaces-instead-of-tabs', 'right-margin-position', 'show-line-marks', 'show-line-numbers', 'show-right-margin', 'smart-backspace', 'smart-home-end', 'tab-width'],
|
|
29
54
|
};
|
|
30
55
|
|
|
31
56
|
export const OWN_SIGNALS = {
|
|
57
|
+
GtkSourceAnnotationProvider: ['changed'],
|
|
58
|
+
GtkSourceAnnotations: ['changed'],
|
|
59
|
+
GtkSourceBuffer: ['bracket-matched', 'cursor-moved', 'highlight-updated', 'source-mark-updated'],
|
|
60
|
+
GtkSourceCompletion: ['hide', 'provider-added', 'provider-removed', 'show'],
|
|
61
|
+
GtkSourceCompletionContext: ['provider-model-changed'],
|
|
32
62
|
GtkSourceGutterRenderer: ['activate', 'query-activatable', 'query-data'],
|
|
63
|
+
GtkSourceMarkAttributes: ['query-tooltip-markup', 'query-tooltip-text'],
|
|
64
|
+
GtkSourceSnippetContext: ['changed'],
|
|
33
65
|
GtkSourceStyleSchemePreview: ['activate'],
|
|
34
66
|
GtkSourceView: ['change-case', 'change-number', 'join-lines', 'line-mark-activated', 'move-lines', 'move-to-matching-bracket', 'move-words', 'push-snippet', 'show-completion', 'smart-home-end'],
|
|
67
|
+
GtkSourceVimIMContext: ['edit', 'execute-command', 'format-text', 'write'],
|
|
35
68
|
};
|
|
36
69
|
|
|
70
|
+
// Every GType this namespace can INSTANTIATE -> the declarations its members come from.
|
|
71
|
+
//
|
|
72
|
+
// The key set is what a UI description file can name: a registered, non-abstract class.
|
|
73
|
+
// Not "every widget" — GtkBuilder resolves a name through `g_type_from_name`, which knows
|
|
74
|
+
// nothing about widgets, and a `.ui` file is full of `GtkSizeGroup`, `GtkTextTag`,
|
|
75
|
+
// `GtkEventController*` and `GtkCellRenderer*`. Use `Widgets` and `CHILD_HOLDERS`
|
|
76
|
+
// below for the narrower questions; they did not move.
|
|
37
77
|
export const DECLS = {
|
|
78
|
+
GtkSourceAnnotation: ['GtkSourceAnnotation'],
|
|
79
|
+
GtkSourceAnnotationProvider: ['GtkSourceAnnotationProvider'],
|
|
80
|
+
GtkSourceAnnotations: ['GtkSourceAnnotations'],
|
|
81
|
+
GtkSourceBuffer: ['GtkSourceBuffer', 'GtkTextBuffer'],
|
|
82
|
+
GtkSourceCompletion: ['GtkSourceCompletion'],
|
|
38
83
|
GtkSourceCompletionCell: ['GtkSourceCompletionCell', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
|
|
84
|
+
GtkSourceCompletionContext: ['GtkSourceCompletionContext'],
|
|
85
|
+
GtkSourceCompletionSnippets: ['GtkSourceCompletionSnippets', 'GtkSourceCompletionProvider'],
|
|
86
|
+
GtkSourceCompletionWords: ['GtkSourceCompletionWords', 'GtkSourceCompletionProvider'],
|
|
87
|
+
GtkSourceFile: ['GtkSourceFile'],
|
|
88
|
+
GtkSourceFileLoader: ['GtkSourceFileLoader'],
|
|
89
|
+
GtkSourceFileSaver: ['GtkSourceFileSaver'],
|
|
39
90
|
GtkSourceGutter: ['GtkSourceGutter', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
|
|
91
|
+
GtkSourceGutterLines: ['GtkSourceGutterLines'],
|
|
40
92
|
GtkSourceGutterRendererPixbuf: ['GtkSourceGutterRendererPixbuf', 'GtkSourceGutterRenderer', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
|
|
41
93
|
GtkSourceGutterRendererText: ['GtkSourceGutterRendererText', 'GtkSourceGutterRenderer', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
|
|
94
|
+
GtkSourceHover: ['GtkSourceHover'],
|
|
95
|
+
GtkSourceHoverContext: ['GtkSourceHoverContext'],
|
|
42
96
|
GtkSourceHoverDisplay: ['GtkSourceHoverDisplay', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget'],
|
|
97
|
+
GtkSourceLanguage: ['GtkSourceLanguage'],
|
|
98
|
+
GtkSourceLanguageManager: ['GtkSourceLanguageManager'],
|
|
43
99
|
GtkSourceMap: ['GtkSourceMap', 'GtkSourceView', 'GtkTextView', 'GtkWidget', 'GtkAccessible', 'GtkAccessibleText', 'GtkBuildable', 'GtkConstraintTarget', 'GtkScrollable'],
|
|
100
|
+
GtkSourceMark: ['GtkSourceMark', 'GtkTextMark'],
|
|
101
|
+
GtkSourceMarkAttributes: ['GtkSourceMarkAttributes'],
|
|
102
|
+
GtkSourcePrintCompositor: ['GtkSourcePrintCompositor'],
|
|
103
|
+
GtkSourceRegion: ['GtkSourceRegion'],
|
|
104
|
+
GtkSourceSearchContext: ['GtkSourceSearchContext'],
|
|
105
|
+
GtkSourceSearchSettings: ['GtkSourceSearchSettings'],
|
|
106
|
+
GtkSourceSnippet: ['GtkSourceSnippet'],
|
|
107
|
+
GtkSourceSnippetChunk: ['GtkSourceSnippetChunk'],
|
|
108
|
+
GtkSourceSnippetContext: ['GtkSourceSnippetContext'],
|
|
109
|
+
GtkSourceSnippetManager: ['GtkSourceSnippetManager'],
|
|
110
|
+
GtkSourceSpaceDrawer: ['GtkSourceSpaceDrawer'],
|
|
111
|
+
GtkSourceStyle: ['GtkSourceStyle'],
|
|
112
|
+
GtkSourceStyleScheme: ['GtkSourceStyleScheme'],
|
|
44
113
|
GtkSourceStyleSchemeChooserButton: ['GtkSourceStyleSchemeChooserButton', 'GtkButton', 'GtkWidget', 'GtkAccessible', 'GtkActionable', 'GtkBuildable', 'GtkConstraintTarget', 'GtkSourceStyleSchemeChooser'],
|
|
45
114
|
GtkSourceStyleSchemeChooserWidget: ['GtkSourceStyleSchemeChooserWidget', 'GtkWidget', 'GtkAccessible', 'GtkBuildable', 'GtkConstraintTarget', 'GtkSourceStyleSchemeChooser'],
|
|
115
|
+
GtkSourceStyleSchemeManager: ['GtkSourceStyleSchemeManager'],
|
|
46
116
|
GtkSourceStyleSchemePreview: ['GtkSourceStyleSchemePreview', 'GtkWidget', 'GtkAccessible', 'GtkActionable', 'GtkBuildable', 'GtkConstraintTarget'],
|
|
117
|
+
GtkSourceTag: ['GtkSourceTag', 'GtkTextTag'],
|
|
47
118
|
GtkSourceView: ['GtkSourceView', 'GtkTextView', 'GtkWidget', 'GtkAccessible', 'GtkAccessibleText', 'GtkBuildable', 'GtkConstraintTarget', 'GtkScrollable'],
|
|
119
|
+
GtkSourceVimIMContext: ['GtkSourceVimIMContext', 'GtkIMContext'],
|
|
48
120
|
};
|
|
49
121
|
|
|
50
|
-
// The GTypes above that are
|
|
51
|
-
//
|
|
52
|
-
//
|
|
53
|
-
//
|
|
122
|
+
// The GTypes above that ARE widgets are the `Widgets` map in the sibling `.d.ts`; these
|
|
123
|
+
// are the ones that merely HOLD one, through `set_child`/`get_child`, descending from
|
|
124
|
+
// `GObject.Object`. A renderer places them like a container; a check asking "is this a
|
|
125
|
+
// widget" must not count them. Derived from the accessor pair, never from a list — the
|
|
126
|
+
// count is in the provenance line above.
|
|
54
127
|
export const CHILD_HOLDERS = [];
|
|
55
128
|
|
|
56
129
|
export const ENUM_NICKS = {
|
|
@@ -65,6 +138,8 @@ export const ENUM_NICKS = {
|
|
|
65
138
|
GtkSourceNewlineType: ['lf', 'cr', 'cr-lf'],
|
|
66
139
|
GtkSourceSmartHomeEndType: ['disabled', 'before', 'after', 'always'],
|
|
67
140
|
GtkSourceViewGutterPosition: ['lines', 'marks'],
|
|
141
|
+
PangoUnderline: ['none', 'single', 'double', 'low', 'error', 'single-line', 'double-line', 'error-line'],
|
|
142
|
+
PangoWeight: ['thin', 'ultralight', 'light', 'semilight', 'book', 'normal', 'medium', 'semibold', 'bold', 'ultrabold', 'heavy', 'ultraheavy'],
|
|
68
143
|
};
|
|
69
144
|
|
|
70
145
|
// The number behind each of those nicks, read from GIR's own `value` attribute.
|
|
@@ -72,7 +147,7 @@ export const ENUM_NICKS = {
|
|
|
72
147
|
// It ships because position in `ENUM_NICKS` is not the value and a consumer with no
|
|
73
148
|
// typelib has no other way to learn it: a surface without GI still has to hand GObject an
|
|
74
149
|
// integer. The alternative a consumer reaches for first is counting, and counting is wrong
|
|
75
|
-
// on 6 of the
|
|
150
|
+
// on 6 of the 137 enums a GTK 4 vocabulary carries (112 in Gtk-4.0, 25 in Adw-1) --
|
|
76
151
|
// `GtkResponseType` runs -1 down to
|
|
77
152
|
// -11, `GtkTextWindowType` starts at 1, and `GtkConstraintStrength.required` is
|
|
78
153
|
// 1001001000 where counting answers 0.
|
|
@@ -119,6 +194,26 @@ export const ENUM_VALUES = {
|
|
|
119
194
|
'GtkSourceSmartHomeEndType.disabled': 0,
|
|
120
195
|
'GtkSourceViewGutterPosition.lines': -30,
|
|
121
196
|
'GtkSourceViewGutterPosition.marks': -20,
|
|
197
|
+
'PangoUnderline.double': 2,
|
|
198
|
+
'PangoUnderline.double-line': 6,
|
|
199
|
+
'PangoUnderline.error': 4,
|
|
200
|
+
'PangoUnderline.error-line': 7,
|
|
201
|
+
'PangoUnderline.low': 3,
|
|
202
|
+
'PangoUnderline.none': 0,
|
|
203
|
+
'PangoUnderline.single': 1,
|
|
204
|
+
'PangoUnderline.single-line': 5,
|
|
205
|
+
'PangoWeight.bold': 700,
|
|
206
|
+
'PangoWeight.book': 380,
|
|
207
|
+
'PangoWeight.heavy': 900,
|
|
208
|
+
'PangoWeight.light': 300,
|
|
209
|
+
'PangoWeight.medium': 500,
|
|
210
|
+
'PangoWeight.normal': 400,
|
|
211
|
+
'PangoWeight.semibold': 600,
|
|
212
|
+
'PangoWeight.semilight': 350,
|
|
213
|
+
'PangoWeight.thin': 100,
|
|
214
|
+
'PangoWeight.ultrabold': 800,
|
|
215
|
+
'PangoWeight.ultraheavy': 1000,
|
|
216
|
+
'PangoWeight.ultralight': 200,
|
|
122
217
|
};
|
|
123
218
|
|
|
124
219
|
// The nicks GIR marks `deprecated="1"`.
|
|
@@ -147,11 +242,12 @@ export const ENUM_VALUES_UNREADABLE = {};
|
|
|
147
242
|
// The number behind each member of a registered BITFIELD, keyed the same way.
|
|
148
243
|
//
|
|
149
244
|
// `ENUM_NICKS` refuses a bitfield because GObject cannot resolve a nick SET, and that
|
|
150
|
-
// reason says nothing about one member's number.
|
|
151
|
-
//
|
|
152
|
-
// `AdwTabView:shortcuts`, ... -- and they are typed bare
|
|
153
|
-
// has nothing to compute one from. Counting is worst
|
|
154
|
-
//
|
|
245
|
+
// reason says nothing about one member's number. 23 settable properties in Gtk-4.0 and
|
|
246
|
+
// Adw-1 are bitfield-typed -- `GtkEntry:input-hints`, `GtkPopoverMenu:flags`,
|
|
247
|
+
// `AdwTabView:shortcuts`, `GtkDropTarget:actions`, ... -- and they are typed bare
|
|
248
|
+
// `number`, so a host without GI has nothing to compute one from. Counting is worst
|
|
249
|
+
// exactly here: 119 of the 156 Gtk-4.0 bitfield members this vocabulary carries disagree
|
|
250
|
+
// with their declaration position, against 29 of 672 enumeration members.
|
|
155
251
|
//
|
|
156
252
|
// A table of its own rather than more rows in `ENUM_VALUES`, so that "every nick in
|
|
157
253
|
// `ENUM_NICKS` has a number or a declared reason" stays a claim about one set.
|
|
@@ -195,12 +291,18 @@ export const FLAG_VALUES_UNREADABLE = {};
|
|
|
195
291
|
// one are both entries a consumer would resolve wrongly, so neither is written.
|
|
196
292
|
//
|
|
197
293
|
// A GType named here has numbers in SOME vocabulary, not necessarily this one: the namespace
|
|
198
|
-
// that OWNS an enum publishes it, so
|
|
294
|
+
// that OWNS an enum publishes it, so 83 of the 909 entries a full run emits want the owner's
|
|
199
295
|
// vocabulary loaded too. Owners that emit none (Gdk, Pango) are inlined into the tables above.
|
|
200
296
|
export const PROP_ENUMS = {
|
|
201
297
|
'GtkSourceCompletionCell.column': 'GtkSourceCompletionColumn',
|
|
298
|
+
'GtkSourceFileSaver.compression-type': 'GtkSourceCompressionType',
|
|
299
|
+
'GtkSourceFileSaver.flags': 'GtkSourceFileSaverFlags',
|
|
300
|
+
'GtkSourceFileSaver.newline-type': 'GtkSourceNewlineType',
|
|
202
301
|
'GtkSourceGutter.window-type': 'GtkTextWindowType',
|
|
203
302
|
'GtkSourceGutterRenderer.alignment-mode': 'GtkSourceGutterRendererAlignmentMode',
|
|
303
|
+
'GtkSourcePrintCompositor.wrap-mode': 'GtkWrapMode',
|
|
304
|
+
'GtkSourceStyle.pango-underline': 'PangoUnderline',
|
|
305
|
+
'GtkSourceStyle.weight': 'PangoWeight',
|
|
204
306
|
'GtkSourceView.background-pattern': 'GtkSourceBackgroundPatternType',
|
|
205
307
|
'GtkSourceView.smart-home-end': 'GtkSourceSmartHomeEndType',
|
|
206
308
|
};
|
|
@@ -240,5 +342,17 @@ export const SLOT_CANDIDATES = {
|
|
|
240
342
|
};
|
|
241
343
|
|
|
242
344
|
export const SINCE = {
|
|
345
|
+
'GtkSourceAnnotation': '5.18',
|
|
346
|
+
'GtkSourceAnnotationProvider': '5.18',
|
|
347
|
+
'GtkSourceAnnotationProvider::changed': '5.18',
|
|
348
|
+
'GtkSourceAnnotations': '5.18',
|
|
349
|
+
'GtkSourceCompletionContext::provider-model-changed': '5.6',
|
|
350
|
+
'GtkSourceFileLoader.max-size': '5.22',
|
|
351
|
+
'GtkSourceSearchSettings.visible-only': '5.12',
|
|
243
352
|
'GtkSourceStyleSchemePreview': '5.4',
|
|
353
|
+
'GtkSourceVimIMContext': '5.4',
|
|
354
|
+
'GtkSourceVimIMContext::edit': '5.4',
|
|
355
|
+
'GtkSourceVimIMContext::execute-command': '5.4',
|
|
356
|
+
'GtkSourceVimIMContext::format-text': '5.4',
|
|
357
|
+
'GtkSourceVimIMContext::write': '5.4',
|
|
244
358
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@girs/gtksource-5",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.2.0",
|
|
4
4
|
"libraryVersion": "5.21.0",
|
|
5
5
|
"description": "GJS TypeScript type definitions for GtkSource-5, generated from library version 5.21.0",
|
|
6
6
|
"type": "module",
|
|
@@ -37,21 +37,21 @@
|
|
|
37
37
|
"test": "tsc --project tsconfig.json"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@girs/gjs": "^5.
|
|
41
|
-
"@girs/gtk-4.0": "^5.
|
|
42
|
-
"@girs/gsk-4.0": "^5.
|
|
43
|
-
"@girs/graphene-1.0": "^5.
|
|
44
|
-
"@girs/gobject-2.0": "^5.
|
|
45
|
-
"@girs/glib-2.0": "^5.
|
|
46
|
-
"@girs/gdk-4.0": "^5.
|
|
47
|
-
"@girs/cairo-1.0": "^5.
|
|
48
|
-
"@girs/pangocairo-1.0": "^5.
|
|
49
|
-
"@girs/pango-1.0": "^5.
|
|
50
|
-
"@girs/harfbuzz-0.0": "^5.
|
|
51
|
-
"@girs/freetype2-2.0": "^5.
|
|
52
|
-
"@girs/gio-2.0": "^5.
|
|
53
|
-
"@girs/gmodule-2.0": "^5.
|
|
54
|
-
"@girs/gdkpixbuf-2.0": "^5.
|
|
40
|
+
"@girs/gjs": "^5.2.0",
|
|
41
|
+
"@girs/gtk-4.0": "^5.2.0",
|
|
42
|
+
"@girs/gsk-4.0": "^5.2.0",
|
|
43
|
+
"@girs/graphene-1.0": "^5.2.0",
|
|
44
|
+
"@girs/gobject-2.0": "^5.2.0",
|
|
45
|
+
"@girs/glib-2.0": "^5.2.0",
|
|
46
|
+
"@girs/gdk-4.0": "^5.2.0",
|
|
47
|
+
"@girs/cairo-1.0": "^5.2.0",
|
|
48
|
+
"@girs/pangocairo-1.0": "^5.2.0",
|
|
49
|
+
"@girs/pango-1.0": "^5.2.0",
|
|
50
|
+
"@girs/harfbuzz-0.0": "^5.2.0",
|
|
51
|
+
"@girs/freetype2-2.0": "^5.2.0",
|
|
52
|
+
"@girs/gio-2.0": "^5.2.0",
|
|
53
|
+
"@girs/gmodule-2.0": "^5.2.0",
|
|
54
|
+
"@girs/gdkpixbuf-2.0": "^5.2.0" },
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"typescript": "*"
|
|
57
57
|
},
|