@revizly/sharp-libvips-dev 1.0.32 → 1.0.34

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.
Files changed (59) hide show
  1. package/README.md +15 -15
  2. package/include/aom/aom_codec.h +1 -1
  3. package/include/aom/aom_decoder.h +4 -0
  4. package/include/aom/aom_encoder.h +19 -8
  5. package/include/aom/aom_ext_ratectrl.h +664 -0
  6. package/include/aom/aom_image.h +93 -30
  7. package/include/aom/aom_tpl.h +99 -0
  8. package/include/aom/aomcx.h +89 -16
  9. package/include/aom/aomdx.h +12 -0
  10. package/include/expat.h +1 -1
  11. package/include/expat_config.h +3 -3
  12. package/include/fontconfig/fcfreetype.h +14 -0
  13. package/include/fontconfig/fcprivate.h +8 -1
  14. package/include/fontconfig/fontconfig.h +45 -17
  15. package/include/glib-2.0/gio/gdbusconnection.h +2 -8
  16. package/include/glib-2.0/gio/gio-visibility.h +34 -0
  17. package/include/glib-2.0/gio/gioenums.h +5 -4
  18. package/include/glib-2.0/girepository/gi-visibility.h +34 -0
  19. package/include/glib-2.0/glib/glib-visibility.h +34 -0
  20. package/include/glib-2.0/glib/gmacros.h +3 -3
  21. package/include/glib-2.0/glib/gmarkup.h +10 -0
  22. package/include/glib-2.0/glib/gmem.h +4 -4
  23. package/include/glib-2.0/glib/gmessages.h +6 -8
  24. package/include/glib-2.0/glib/gsequence.h +2 -2
  25. package/include/glib-2.0/glib/gstrfuncs.h +190 -0
  26. package/include/glib-2.0/glib/gutils.h +9 -0
  27. package/include/glib-2.0/glib/gversionmacros.h +9 -0
  28. package/include/glib-2.0/gmodule/gmodule-visibility.h +34 -0
  29. package/include/glib-2.0/gobject/gobject-visibility.h +34 -0
  30. package/include/glib-2.0/gobject/gsignal.h +5 -5
  31. package/include/glib-2.0/gobject/gtype.h +14 -14
  32. package/include/libde265/de265-version.h +2 -2
  33. package/include/libde265/de265.h +13 -1
  34. package/include/libheif/heif.h +2 -0
  35. package/include/libheif/heif_color.h +8 -8
  36. package/include/libheif/heif_components.h +264 -0
  37. package/include/libheif/heif_context.h +2 -1
  38. package/include/libheif/heif_cxx.h +10 -10
  39. package/include/libheif/heif_decoding.h +21 -7
  40. package/include/libheif/heif_encoding.h +15 -9
  41. package/include/libheif/heif_error.h +7 -2
  42. package/include/libheif/heif_image.h +81 -66
  43. package/include/libheif/heif_image_handle.h +2 -2
  44. package/include/libheif/heif_items.h +1 -1
  45. package/include/libheif/heif_omaf.h +104 -0
  46. package/include/libheif/heif_plugin.h +16 -9
  47. package/include/libheif/heif_properties.h +247 -12
  48. package/include/libheif/heif_security.h +16 -4
  49. package/include/libheif/heif_sequences.h +74 -2
  50. package/include/libheif/heif_tiling.h +2 -2
  51. package/include/libheif/heif_uncompressed.h +44 -324
  52. package/include/libheif/heif_version.h +2 -2
  53. package/include/librsvg-2.0/librsvg/rsvg-version.h +2 -2
  54. package/include/tiffio.h +1 -0
  55. package/include/ultrahdr_api.h +5 -11
  56. package/package.json +2 -2
  57. package/versions.json +10 -10
  58. package/include/libheif/heif_uncompressed_types.h +0 -143
  59. package/include/librsvg-2.0/librsvg/rsvg-pixbuf.h +0 -235
@@ -54,8 +54,8 @@ typedef int FcBool;
54
54
  */
55
55
 
56
56
  #define FC_MAJOR 2
57
- #define FC_MINOR 17
58
- #define FC_REVISION 1
57
+ #define FC_MINOR 18
58
+ #define FC_REVISION 0
59
59
 
60
60
  #define FC_VERSION ((FC_MAJOR * 10000) + (FC_MINOR * 100) + (FC_REVISION))
61
61
 
@@ -69,7 +69,7 @@ typedef int FcBool;
69
69
  * it means multiple copies of the font information.
70
70
  */
71
71
 
72
- #define FC_CACHE_VERSION_NUMBER 9
72
+ #define FC_CACHE_VERSION_NUMBER 11
73
73
  #define _FC_STRINGIFY_(s) #s
74
74
  #define _FC_STRINGIFY(s) _FC_STRINGIFY_ (s)
75
75
  #define FC_CACHE_VERSION _FC_STRINGIFY (FC_CACHE_VERSION_NUMBER)
@@ -133,6 +133,7 @@ typedef int FcBool;
133
133
  #define FC_DESKTOP_NAME "desktop" /* String */
134
134
  #define FC_NAMED_INSTANCE "namedinstance" /* Bool - true if font is named instance */
135
135
  #define FC_FONT_WRAPPER "fontwrapper" /* String */
136
+ #define FC_GENERIC_FAMILY "genericfamily" /* Integer */
136
137
 
137
138
  #define FC_CACHE_SUFFIX ".cache-" FC_CACHE_VERSION
138
139
  #define FC_DIR_CACHE_FILE "fonts.cache-" FC_CACHE_VERSION
@@ -178,10 +179,14 @@ typedef int FcBool;
178
179
  #define FC_WIDTH_EXTRAEXPANDED 150
179
180
  #define FC_WIDTH_ULTRAEXPANDED 200
180
181
 
181
- #define FC_PROPORTIONAL 0
182
- #define FC_DUAL 90
183
- #define FC_MONO 100
184
- #define FC_CHARCELL 110
182
+ #define FC_SPACING_PROPORTIONAL 0
183
+ #define FC_SPACING_DUAL 90
184
+ #define FC_SPACING_MONO 100
185
+ #define FC_SPACING_CHARCELL 110
186
+ #define FC_PROPORTIONAL FC_SPACING_PROPORTIONAL
187
+ #define FC_DUAL FC_SPACING_DUAL
188
+ #define FC_MONO FC_SPACING_MONO
189
+ #define FC_CHARCELL FC_SPACING_CHARCELL
185
190
 
186
191
  /* sub-pixel order */
187
192
  #define FC_RGBA_UNKNOWN 0
@@ -203,6 +208,22 @@ typedef int FcBool;
203
208
  #define FC_LCD_LIGHT 2
204
209
  #define FC_LCD_LEGACY 3
205
210
 
211
+ /* Generic family */
212
+ #define FC_FAMILY_UNKNOWN 0
213
+ #define FC_FAMILY_SERIF 1
214
+ #define FC_FAMILY_SANS 2
215
+ #define FC_FAMILY_MONO 3
216
+ #define FC_FAMILY_CURSIVE 4
217
+ #define FC_FAMILY_FANTASY 5
218
+ #define FC_FAMILY_SYSTEM_UI 6
219
+ #define FC_FAMILY_UI_SERIF 7
220
+ #define FC_FAMILY_UI_SANS 8
221
+ #define FC_FAMILY_UI_MONO 9
222
+ #define FC_FAMILY_UI_ROUNDED 10
223
+ #define FC_FAMILY_EMOJI 11
224
+ #define FC_FAMILY_MATH 12
225
+ #define FC_FAMILY_FANGSONG 13
226
+
206
227
  typedef enum _FcType {
207
228
  FcTypeUnknown = -1,
208
229
  FcTypeVoid,
@@ -217,6 +238,8 @@ typedef enum _FcType {
217
238
  FcTypeRange
218
239
  } FcType;
219
240
 
241
+ typedef int FcObject;
242
+
220
243
  typedef struct _FcMatrix {
221
244
  double xx, xy, yx, yy;
222
245
  } FcMatrix;
@@ -291,9 +314,11 @@ typedef struct _FcFontSet {
291
314
  } FcFontSet;
292
315
 
293
316
  typedef struct _FcObjectSet {
294
- int nobject;
317
+ int nobject; /* deprecated */
295
318
  int sobject;
296
- const char **objects;
319
+ const char **objects; /* deprecated */
320
+ int nobjIds;
321
+ FcObject *objIds;
297
322
  } FcObjectSet;
298
323
 
299
324
  typedef enum _FcMatchKind {
@@ -659,13 +684,6 @@ FcDirCacheLoadFile (const FcChar8 *cache_file, struct stat *file_stat);
659
684
  FcPublic void
660
685
  FcDirCacheUnload (FcCache *cache);
661
686
 
662
- /* fcfreetype.c */
663
- FcPublic FcPattern *
664
- FcFreeTypeQuery (const FcChar8 *file, unsigned int id, FcBlanks *blanks, int *count);
665
-
666
- FcPublic unsigned int
667
- FcFreeTypeQueryAll (const FcChar8 *file, unsigned int id, FcBlanks *blanks, int *count, FcFontSet *set);
668
-
669
687
  /* fcfs.c */
670
688
 
671
689
  FcPublic FcFontSet *
@@ -888,6 +906,9 @@ FcNameGetConstantFor (const FcChar8 *string, const char *object);
888
906
  FcPublic FcBool
889
907
  FcNameConstant (const FcChar8 *string, int *result);
890
908
 
909
+ FcPublic const FcChar8 *
910
+ FcNameGetConstantNameFrom (const char *object, int value);
911
+
891
912
  FcPublic FcPattern *
892
913
  FcNameParse (const FcChar8 *name);
893
914
 
@@ -919,7 +940,7 @@ FcValueSave (FcValue v);
919
940
  FcPublic void
920
941
  FcPatternDestroy (FcPattern *p);
921
942
 
922
- int
943
+ FcPublic int
923
944
  FcPatternObjectCount (const FcPattern *pat);
924
945
 
925
946
  FcPublic FcBool
@@ -1177,6 +1198,13 @@ FcConfigParseAndLoadFromMemory (FcConfig *config,
1177
1198
  const FcChar8 *buffer,
1178
1199
  FcBool complain);
1179
1200
 
1201
+ /* fcconffile.c */
1202
+ FcPublic FcChar8 *
1203
+ FcConfigFileGenerate (FcConfig *config,
1204
+ FcPattern *pat,
1205
+ const FcChar8 *font_path);
1206
+
1207
+
1180
1208
  _FCFUNCPROTOEND
1181
1209
 
1182
1210
  #undef FC_ATTRIBUTE_SENTINEL
@@ -406,10 +406,7 @@ struct _GDBusInterfaceVTable
406
406
  GDBusInterfaceSetPropertyFunc set_property;
407
407
 
408
408
  /*< private >*/
409
- /* Padding for future expansion - also remember to update
410
- * gdbusconnection.c:_g_dbus_interface_vtable_copy() when
411
- * changing this.
412
- */
409
+ /* Padding for future expansion */
413
410
  gpointer padding[8];
414
411
  };
415
412
 
@@ -552,10 +549,7 @@ struct _GDBusSubtreeVTable
552
549
  GDBusSubtreeDispatchFunc dispatch;
553
550
 
554
551
  /*< private >*/
555
- /* Padding for future expansion - also remember to update
556
- * gdbusconnection.c:_g_dbus_subtree_vtable_copy() when
557
- * changing this.
558
- */
552
+ /* Padding for future expansion */
559
553
  gpointer padding[8];
560
554
  };
561
555
 
@@ -1120,3 +1120,37 @@
1120
1120
  #define GIO_AVAILABLE_ENUMERATOR_IN_2_88
1121
1121
  #define GIO_AVAILABLE_TYPE_IN_2_88
1122
1122
  #endif
1123
+
1124
+ #if GLIB_VERSION_MIN_REQUIRED >= GLIB_VERSION_2_90
1125
+ #define GIO_DEPRECATED_IN_2_90 GIO_DEPRECATED
1126
+ #define GIO_DEPRECATED_IN_2_90_FOR(f) GIO_DEPRECATED_FOR (f)
1127
+ #define GIO_DEPRECATED_MACRO_IN_2_90 GLIB_DEPRECATED_MACRO
1128
+ #define GIO_DEPRECATED_MACRO_IN_2_90_FOR(f) GLIB_DEPRECATED_MACRO_FOR (f)
1129
+ #define GIO_DEPRECATED_ENUMERATOR_IN_2_90 GLIB_DEPRECATED_ENUMERATOR
1130
+ #define GIO_DEPRECATED_ENUMERATOR_IN_2_90_FOR(f) GLIB_DEPRECATED_ENUMERATOR_FOR (f)
1131
+ #define GIO_DEPRECATED_TYPE_IN_2_90 GLIB_DEPRECATED_TYPE
1132
+ #define GIO_DEPRECATED_TYPE_IN_2_90_FOR(f) GLIB_DEPRECATED_TYPE_FOR (f)
1133
+ #else
1134
+ #define GIO_DEPRECATED_IN_2_90 _GIO_EXTERN
1135
+ #define GIO_DEPRECATED_IN_2_90_FOR(f) _GIO_EXTERN
1136
+ #define GIO_DEPRECATED_MACRO_IN_2_90
1137
+ #define GIO_DEPRECATED_MACRO_IN_2_90_FOR(f)
1138
+ #define GIO_DEPRECATED_ENUMERATOR_IN_2_90
1139
+ #define GIO_DEPRECATED_ENUMERATOR_IN_2_90_FOR(f)
1140
+ #define GIO_DEPRECATED_TYPE_IN_2_90
1141
+ #define GIO_DEPRECATED_TYPE_IN_2_90_FOR(f)
1142
+ #endif
1143
+
1144
+ #if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_90
1145
+ #define GIO_AVAILABLE_IN_2_90 GIO_UNAVAILABLE (2, 90)
1146
+ #define GIO_AVAILABLE_STATIC_INLINE_IN_2_90 GLIB_UNAVAILABLE_STATIC_INLINE (2, 90)
1147
+ #define GIO_AVAILABLE_MACRO_IN_2_90 GLIB_UNAVAILABLE_MACRO (2, 90)
1148
+ #define GIO_AVAILABLE_ENUMERATOR_IN_2_90 GLIB_UNAVAILABLE_ENUMERATOR (2, 90)
1149
+ #define GIO_AVAILABLE_TYPE_IN_2_90 GLIB_UNAVAILABLE_TYPE (2, 90)
1150
+ #else
1151
+ #define GIO_AVAILABLE_IN_2_90 _GIO_EXTERN
1152
+ #define GIO_AVAILABLE_STATIC_INLINE_IN_2_90
1153
+ #define GIO_AVAILABLE_MACRO_IN_2_90
1154
+ #define GIO_AVAILABLE_ENUMERATOR_IN_2_90
1155
+ #define GIO_AVAILABLE_TYPE_IN_2_90
1156
+ #endif
@@ -799,7 +799,7 @@ typedef enum {
799
799
  *
800
800
  * GResourceFlags give information about a particular file inside a resource
801
801
  * bundle.
802
- *
802
+ *
803
803
  * Since: 2.32
804
804
  **/
805
805
  typedef enum {
@@ -812,7 +812,7 @@ typedef enum {
812
812
  * @G_RESOURCE_LOOKUP_FLAGS_NONE: No flags set.
813
813
  *
814
814
  * GResourceLookupFlags determine how resource path lookups are handled.
815
- *
815
+ *
816
816
  * Since: 2.32
817
817
  **/
818
818
  typedef enum /*< flags >*/ {
@@ -1510,8 +1510,9 @@ typedef enum
1510
1510
  * @G_APPLICATION_IS_LAUNCHER: Don't try to become the primary instance.
1511
1511
  * @G_APPLICATION_HANDLES_OPEN: This application handles opening files (in
1512
1512
  * the primary instance). Note that this flag only affects the default
1513
- * implementation of local_command_line(), and has no effect if
1514
- * %G_APPLICATION_HANDLES_COMMAND_LINE is given.
1513
+ * implementation of local_command_line(). It can be useful even when
1514
+ * using `G_APPLICATION_HANDLES_COMMAND_LINE` to handle
1515
+ * `org.freedesktop.Application.open`.
1515
1516
  * See g_application_run() for details.
1516
1517
  * @G_APPLICATION_HANDLES_COMMAND_LINE: This application handles command line
1517
1518
  * arguments (in the primary instance). Note that this flag only affect
@@ -1120,3 +1120,37 @@
1120
1120
  #define GI_AVAILABLE_ENUMERATOR_IN_2_88
1121
1121
  #define GI_AVAILABLE_TYPE_IN_2_88
1122
1122
  #endif
1123
+
1124
+ #if GLIB_VERSION_MIN_REQUIRED >= GLIB_VERSION_2_90
1125
+ #define GI_DEPRECATED_IN_2_90 GI_DEPRECATED
1126
+ #define GI_DEPRECATED_IN_2_90_FOR(f) GI_DEPRECATED_FOR (f)
1127
+ #define GI_DEPRECATED_MACRO_IN_2_90 GLIB_DEPRECATED_MACRO
1128
+ #define GI_DEPRECATED_MACRO_IN_2_90_FOR(f) GLIB_DEPRECATED_MACRO_FOR (f)
1129
+ #define GI_DEPRECATED_ENUMERATOR_IN_2_90 GLIB_DEPRECATED_ENUMERATOR
1130
+ #define GI_DEPRECATED_ENUMERATOR_IN_2_90_FOR(f) GLIB_DEPRECATED_ENUMERATOR_FOR (f)
1131
+ #define GI_DEPRECATED_TYPE_IN_2_90 GLIB_DEPRECATED_TYPE
1132
+ #define GI_DEPRECATED_TYPE_IN_2_90_FOR(f) GLIB_DEPRECATED_TYPE_FOR (f)
1133
+ #else
1134
+ #define GI_DEPRECATED_IN_2_90 _GI_EXTERN
1135
+ #define GI_DEPRECATED_IN_2_90_FOR(f) _GI_EXTERN
1136
+ #define GI_DEPRECATED_MACRO_IN_2_90
1137
+ #define GI_DEPRECATED_MACRO_IN_2_90_FOR(f)
1138
+ #define GI_DEPRECATED_ENUMERATOR_IN_2_90
1139
+ #define GI_DEPRECATED_ENUMERATOR_IN_2_90_FOR(f)
1140
+ #define GI_DEPRECATED_TYPE_IN_2_90
1141
+ #define GI_DEPRECATED_TYPE_IN_2_90_FOR(f)
1142
+ #endif
1143
+
1144
+ #if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_90
1145
+ #define GI_AVAILABLE_IN_2_90 GI_UNAVAILABLE (2, 90)
1146
+ #define GI_AVAILABLE_STATIC_INLINE_IN_2_90 GLIB_UNAVAILABLE_STATIC_INLINE (2, 90)
1147
+ #define GI_AVAILABLE_MACRO_IN_2_90 GLIB_UNAVAILABLE_MACRO (2, 90)
1148
+ #define GI_AVAILABLE_ENUMERATOR_IN_2_90 GLIB_UNAVAILABLE_ENUMERATOR (2, 90)
1149
+ #define GI_AVAILABLE_TYPE_IN_2_90 GLIB_UNAVAILABLE_TYPE (2, 90)
1150
+ #else
1151
+ #define GI_AVAILABLE_IN_2_90 _GI_EXTERN
1152
+ #define GI_AVAILABLE_STATIC_INLINE_IN_2_90
1153
+ #define GI_AVAILABLE_MACRO_IN_2_90
1154
+ #define GI_AVAILABLE_ENUMERATOR_IN_2_90
1155
+ #define GI_AVAILABLE_TYPE_IN_2_90
1156
+ #endif
@@ -1120,3 +1120,37 @@
1120
1120
  #define GLIB_AVAILABLE_ENUMERATOR_IN_2_88
1121
1121
  #define GLIB_AVAILABLE_TYPE_IN_2_88
1122
1122
  #endif
1123
+
1124
+ #if GLIB_VERSION_MIN_REQUIRED >= GLIB_VERSION_2_90
1125
+ #define GLIB_DEPRECATED_IN_2_90 GLIB_DEPRECATED
1126
+ #define GLIB_DEPRECATED_IN_2_90_FOR(f) GLIB_DEPRECATED_FOR (f)
1127
+ #define GLIB_DEPRECATED_MACRO_IN_2_90 GLIB_DEPRECATED_MACRO
1128
+ #define GLIB_DEPRECATED_MACRO_IN_2_90_FOR(f) GLIB_DEPRECATED_MACRO_FOR (f)
1129
+ #define GLIB_DEPRECATED_ENUMERATOR_IN_2_90 GLIB_DEPRECATED_ENUMERATOR
1130
+ #define GLIB_DEPRECATED_ENUMERATOR_IN_2_90_FOR(f) GLIB_DEPRECATED_ENUMERATOR_FOR (f)
1131
+ #define GLIB_DEPRECATED_TYPE_IN_2_90 GLIB_DEPRECATED_TYPE
1132
+ #define GLIB_DEPRECATED_TYPE_IN_2_90_FOR(f) GLIB_DEPRECATED_TYPE_FOR (f)
1133
+ #else
1134
+ #define GLIB_DEPRECATED_IN_2_90 _GLIB_EXTERN
1135
+ #define GLIB_DEPRECATED_IN_2_90_FOR(f) _GLIB_EXTERN
1136
+ #define GLIB_DEPRECATED_MACRO_IN_2_90
1137
+ #define GLIB_DEPRECATED_MACRO_IN_2_90_FOR(f)
1138
+ #define GLIB_DEPRECATED_ENUMERATOR_IN_2_90
1139
+ #define GLIB_DEPRECATED_ENUMERATOR_IN_2_90_FOR(f)
1140
+ #define GLIB_DEPRECATED_TYPE_IN_2_90
1141
+ #define GLIB_DEPRECATED_TYPE_IN_2_90_FOR(f)
1142
+ #endif
1143
+
1144
+ #if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_90
1145
+ #define GLIB_AVAILABLE_IN_2_90 GLIB_UNAVAILABLE (2, 90)
1146
+ #define GLIB_AVAILABLE_STATIC_INLINE_IN_2_90 GLIB_UNAVAILABLE_STATIC_INLINE (2, 90)
1147
+ #define GLIB_AVAILABLE_MACRO_IN_2_90 GLIB_UNAVAILABLE_MACRO (2, 90)
1148
+ #define GLIB_AVAILABLE_ENUMERATOR_IN_2_90 GLIB_UNAVAILABLE_ENUMERATOR (2, 90)
1149
+ #define GLIB_AVAILABLE_TYPE_IN_2_90 GLIB_UNAVAILABLE_TYPE (2, 90)
1150
+ #else
1151
+ #define GLIB_AVAILABLE_IN_2_90 _GLIB_EXTERN
1152
+ #define GLIB_AVAILABLE_STATIC_INLINE_IN_2_90
1153
+ #define GLIB_AVAILABLE_MACRO_IN_2_90
1154
+ #define GLIB_AVAILABLE_ENUMERATOR_IN_2_90
1155
+ #define GLIB_AVAILABLE_TYPE_IN_2_90
1156
+ #endif
@@ -782,7 +782,7 @@
782
782
  /**
783
783
  * G_GNUC_FLAG_ENUM:
784
784
  *
785
- * Expands to the GNU C `flag_enum` attribute if the compiler is gcc or clang.
785
+ * Expands to the GNU C `flag_enum` attribute if the compiler is `gcc` or `clang`.
786
786
  * This attribute indicates that an enumerated type is used in bitwise
787
787
  * operations.
788
788
  * It is sometimes used in static analysis.
@@ -799,9 +799,9 @@
799
799
  * } G_GNUC_FLAG_ENUM GKeyFileFlags;
800
800
  * ]|
801
801
  *
802
- * (The attribute can also be placed after `enum` and before the opening brace,
802
+ * The attribute can also be placed after `enum` and before the opening brace,
803
803
  * but that may cause it to be misinterpreted as the name of the enum if the
804
- * macro is not defined.)
804
+ * macro is not defined.
805
805
  *
806
806
  * Since: 2.88
807
807
  */
@@ -235,6 +235,16 @@ void g_markup_parse_context_get_tag_start (GMarkupParseContext *
235
235
  gsize *line_number,
236
236
  gsize *char_number,
237
237
  gsize *offset);
238
+ GLIB_AVAILABLE_IN_2_90
239
+ void g_markup_parse_context_get_attribute_position
240
+ (GMarkupParseContext *context,
241
+ unsigned int attr,
242
+ size_t *start_lines,
243
+ size_t *start_chars,
244
+ size_t *start_offset,
245
+ size_t *end_lines,
246
+ size_t *end_chars,
247
+ size_t *end_offset);
238
248
 
239
249
  GLIB_AVAILABLE_IN_ALL
240
250
  gpointer g_markup_parse_context_get_user_data (GMarkupParseContext *context);
@@ -86,14 +86,14 @@ GLIB_AVAILABLE_IN_ALL
86
86
  gpointer g_malloc0 (gsize n_bytes) G_GNUC_MALLOC G_GNUC_ALLOC_SIZE(1);
87
87
  GLIB_AVAILABLE_IN_ALL
88
88
  gpointer g_realloc (gpointer mem,
89
- gsize n_bytes) G_GNUC_WARN_UNUSED_RESULT;
89
+ gsize n_bytes) G_GNUC_WARN_UNUSED_RESULT G_GNUC_ALLOC_SIZE(2);
90
90
  GLIB_AVAILABLE_IN_ALL
91
91
  gpointer g_try_malloc (gsize n_bytes) G_GNUC_MALLOC G_GNUC_ALLOC_SIZE(1);
92
92
  GLIB_AVAILABLE_IN_ALL
93
93
  gpointer g_try_malloc0 (gsize n_bytes) G_GNUC_MALLOC G_GNUC_ALLOC_SIZE(1);
94
94
  GLIB_AVAILABLE_IN_ALL
95
95
  gpointer g_try_realloc (gpointer mem,
96
- gsize n_bytes) G_GNUC_WARN_UNUSED_RESULT;
96
+ gsize n_bytes) G_GNUC_WARN_UNUSED_RESULT G_GNUC_ALLOC_SIZE(2);
97
97
 
98
98
  GLIB_AVAILABLE_IN_ALL
99
99
  gpointer g_malloc_n (gsize n_blocks,
@@ -104,7 +104,7 @@ gpointer g_malloc0_n (gsize n_blocks,
104
104
  GLIB_AVAILABLE_IN_ALL
105
105
  gpointer g_realloc_n (gpointer mem,
106
106
  gsize n_blocks,
107
- gsize n_block_bytes) G_GNUC_WARN_UNUSED_RESULT;
107
+ gsize n_block_bytes) G_GNUC_WARN_UNUSED_RESULT G_GNUC_ALLOC_SIZE2(2,3);
108
108
  GLIB_AVAILABLE_IN_ALL
109
109
  gpointer g_try_malloc_n (gsize n_blocks,
110
110
  gsize n_block_bytes) G_GNUC_MALLOC G_GNUC_ALLOC_SIZE2(1,2);
@@ -114,7 +114,7 @@ gpointer g_try_malloc0_n (gsize n_blocks,
114
114
  GLIB_AVAILABLE_IN_ALL
115
115
  gpointer g_try_realloc_n (gpointer mem,
116
116
  gsize n_blocks,
117
- gsize n_block_bytes) G_GNUC_WARN_UNUSED_RESULT;
117
+ gsize n_block_bytes) G_GNUC_WARN_UNUSED_RESULT G_GNUC_ALLOC_SIZE2(2,3);
118
118
 
119
119
  GLIB_AVAILABLE_IN_2_72
120
120
  gpointer g_aligned_alloc (gsize n_blocks,
@@ -32,6 +32,7 @@
32
32
  #endif
33
33
 
34
34
  #include <stdarg.h>
35
+ #include <stdlib.h>
35
36
  #include <glib/gatomic.h>
36
37
  #include <glib/gtypes.h>
37
38
  #include <glib/gmacros.h>
@@ -329,7 +330,7 @@ void g_log_structured_standard (const gchar *log_domain,
329
330
  g_log_structured_standard (G_LOG_DOMAIN, G_LOG_LEVEL_ERROR, \
330
331
  __FILE__, G_STRINGIFY (__LINE__), \
331
332
  G_STRFUNC, __VA_ARGS__); \
332
- for (;;) ; \
333
+ abort (); \
333
334
  } G_STMT_END
334
335
  #define g_message(...) g_log_structured_standard (G_LOG_DOMAIN, G_LOG_LEVEL_MESSAGE, \
335
336
  __FILE__, G_STRINGIFY (__LINE__), \
@@ -347,14 +348,11 @@ void g_log_structured_standard (const gchar *log_domain,
347
348
  __FILE__, G_STRINGIFY (__LINE__), \
348
349
  G_STRFUNC, __VA_ARGS__)
349
350
  #else
350
- /* for(;;) ; so that GCC knows that control doesn't go past g_error().
351
- * Put space before ending semicolon to avoid C++ build warnings.
352
- */
353
351
  #define g_error(...) G_STMT_START { \
354
352
  g_log (G_LOG_DOMAIN, \
355
353
  G_LOG_LEVEL_ERROR, \
356
354
  __VA_ARGS__); \
357
- for (;;) ; \
355
+ abort (); \
358
356
  } G_STMT_END
359
357
  #define g_message(...) g_log (G_LOG_DOMAIN, \
360
358
  G_LOG_LEVEL_MESSAGE, \
@@ -378,7 +376,7 @@ void g_log_structured_standard (const gchar *log_domain,
378
376
  g_log_structured_standard (G_LOG_DOMAIN, G_LOG_LEVEL_ERROR, \
379
377
  __FILE__, G_STRINGIFY (__LINE__), \
380
378
  G_STRFUNC, format); \
381
- for (;;) ; \
379
+ abort (); \
382
380
  } G_STMT_END
383
381
  #define g_message(format...) g_log_structured_standard (G_LOG_DOMAIN, G_LOG_LEVEL_MESSAGE, \
384
382
  __FILE__, G_STRINGIFY (__LINE__), \
@@ -400,7 +398,7 @@ void g_log_structured_standard (const gchar *log_domain,
400
398
  g_log (G_LOG_DOMAIN, \
401
399
  G_LOG_LEVEL_ERROR, \
402
400
  format); \
403
- for (;;) ; \
401
+ abort (); \
404
402
  } G_STMT_END
405
403
 
406
404
  #define g_message(format...) g_log (G_LOG_DOMAIN, \
@@ -432,7 +430,7 @@ g_error (const gchar *format,
432
430
  g_logv (G_LOG_DOMAIN, G_LOG_LEVEL_ERROR, format, args);
433
431
  va_end (args);
434
432
 
435
- for(;;) ;
433
+ abort ();
436
434
  }
437
435
  static inline void
438
436
  g_message (const gchar *format,
@@ -43,7 +43,7 @@ GSequence * g_sequence_new (GDestroyNotify data_des
43
43
  GLIB_AVAILABLE_IN_ALL
44
44
  void g_sequence_free (GSequence *seq);
45
45
  GLIB_AVAILABLE_IN_ALL
46
- gint g_sequence_get_length (GSequence *seq);
46
+ gint g_sequence_get_length (GSequence *seq) G_GNUC_PURE;
47
47
  GLIB_AVAILABLE_IN_ALL
48
48
  void g_sequence_foreach (GSequence *seq,
49
49
  GFunc func,
@@ -62,7 +62,7 @@ void g_sequence_sort_iter (GSequence *seq,
62
62
  GSequenceIterCompareFunc cmp_func,
63
63
  gpointer cmp_data);
64
64
  GLIB_AVAILABLE_IN_2_48
65
- gboolean g_sequence_is_empty (GSequence *seq);
65
+ gboolean g_sequence_is_empty (GSequence *seq) G_GNUC_PURE;
66
66
 
67
67
 
68
68
  /* Getting iters */
@@ -471,6 +471,9 @@ gboolean g_ascii_string_to_unsigned (const gchar *str,
471
471
  * }
472
472
  * ```
473
473
  *
474
+ * See also [func@GLib.set_str_take] for a version of this which steals
475
+ * ownership of @new_str.
476
+ *
474
477
  * Returns: true if the value of @str_pointer changed, false otherwise
475
478
  *
476
479
  * Since: 2.76
@@ -497,6 +500,193 @@ g_set_str (char **str_pointer,
497
500
  return TRUE;
498
501
  }
499
502
 
503
+ /**
504
+ * g_set_str_take: (skip)
505
+ * @str_pointer: (inout) (not optional) (nullable): a pointer to either
506
+ * a string or `NULL`
507
+ * @new_str: (transfer full) (nullable): a string to assign to @str_pointer
508
+ *
509
+ * Updates a pointer to a string to @new_str and returns whether the
510
+ * string was changed. Steals ownership of @new_str.
511
+ *
512
+ * If @new_str matches the previous string, this function will free @new_str and
513
+ * leave @str_pointer unchanged. If @new_str is different, it will be assigned
514
+ * to @str_pointer and the previous string pointed to by @str_pointer will be
515
+ * freed with [func@GLib.free].
516
+ *
517
+ * @str_pointer must not be `NULL`, but can point to a `NULL` value.
518
+ *
519
+ * One convenient usage of this function is in implementing property settings:
520
+ * ```C
521
+ * void
522
+ * foo_set_bar (Foo *foo,
523
+ * const char *new_bar)
524
+ * {
525
+ * g_autofree computed_new_bar = NULL;
526
+ *
527
+ * g_return_if_fail (IS_FOO (foo));
528
+ *
529
+ * computed_new_bar = g_strconcat (new_bar, "some-suffix", NULL);
530
+ *
531
+ * if (g_set_str_take (&foo->bar, g_steal_pointer (&computed_new_bar)))
532
+ * g_object_notify (foo, "bar");
533
+ * }
534
+ * ```
535
+ *
536
+ * See also [func@GLib.set_str] for a version of this which takes a copy of
537
+ * @new_str.
538
+ *
539
+ * Returns: true if the value of @str_pointer changed, false otherwise
540
+ *
541
+ * Since: 2.90
542
+ */
543
+ GLIB_AVAILABLE_STATIC_INLINE_IN_2_90
544
+ static inline gboolean g_set_str_take (char **str_pointer,
545
+ char *new_str);
546
+
547
+ GLIB_AVAILABLE_STATIC_INLINE_IN_2_90
548
+ static inline gboolean
549
+ g_set_str_take (char **str_pointer,
550
+ char *new_str)
551
+ {
552
+ /* You could pass the value of `*str_pointer` in to this function, but you
553
+ * really should do it using g_steal_pointer() to document the ownership
554
+ * transfer. */
555
+ if (*str_pointer == new_str)
556
+ return FALSE;
557
+
558
+ if (*str_pointer != NULL &&
559
+ new_str != NULL &&
560
+ strcmp (*str_pointer, new_str) == 0)
561
+ {
562
+ g_free (new_str);
563
+ return FALSE;
564
+ }
565
+
566
+ g_free (*str_pointer);
567
+ *str_pointer = new_str;
568
+ new_str = NULL; /* stolen */
569
+
570
+ return TRUE;
571
+ }
572
+
573
+ /**
574
+ * g_set_strv: (skip)
575
+ * @strv_pointer: (inout) (not optional) (nullable): a pointer to either
576
+ * a `NULL`-terminated string array or `NULL`
577
+ * @new_strv: (nullable): a NULL-terminated string array to assign to
578
+ * @strv_pointer
579
+ *
580
+ * Safely replaces a string vector.
581
+ *
582
+ * Updates a pointer to a `NULL`-terminated string array to a copy of @new_strv
583
+ * and returns whether the value was changed.
584
+ *
585
+ * If @new_strv matches the previous array, this function is a no-op. If
586
+ * @new_strv is different, a copy of it will be assigned to @strv_pointer and
587
+ * the previous array pointed to by @strv_pointer will be freed with
588
+ * [func@GLib.strfreev].
589
+ *
590
+ * The contents of both string arrays are compared for equality before
591
+ * replacing the value. In the worst case this requires O(N) time.
592
+ *
593
+ * This function avoids a potential use-after-free when @new_strv reuses
594
+ * pointers from the original string array. This allows callers to build
595
+ * a replacement array using existing strings without needing to copy
596
+ * them beforehand.
597
+ *
598
+ * @strv_pointer must not be `NULL`, but can point to a `NULL` value.
599
+ *
600
+ * Returns: true if the value of @strv_pointer changed, false otherwise
601
+ *
602
+ * Since: 2.90
603
+ */
604
+ GLIB_AVAILABLE_STATIC_INLINE_IN_2_90
605
+ static inline gboolean g_set_strv (char ***strv_pointer,
606
+ const char * const *new_strv);
607
+
608
+ GLIB_AVAILABLE_STATIC_INLINE_IN_2_90
609
+ static inline gboolean
610
+ g_set_strv (char ***strv_pointer,
611
+ const char * const *new_strv)
612
+ {
613
+ char **copy;
614
+
615
+ if ((const char * const *)*strv_pointer == new_strv)
616
+ return FALSE;
617
+
618
+ G_GNUC_BEGIN_IGNORE_DEPRECATIONS
619
+ if (*strv_pointer && new_strv &&
620
+ g_strv_equal ((const char * const *)*strv_pointer, new_strv))
621
+ return FALSE;
622
+ G_GNUC_END_IGNORE_DEPRECATIONS
623
+
624
+ copy = g_strdupv ((char **) (guintptr) new_strv);
625
+ g_strfreev (*strv_pointer);
626
+ *strv_pointer = copy;
627
+
628
+ return TRUE;
629
+ }
630
+
631
+ /**
632
+ * g_set_strv_take: (skip)
633
+ * @strv_pointer: (inout) (not optional) (nullable): a pointer to either
634
+ * a `NULL`-terminated string array or `NULL`
635
+ * @new_strv: (transfer full) (nullable): a `NULL`-terminated string array to
636
+ * assign to @strv_pointer
637
+ *
638
+ * Safely replaces a string vector, taking ownership of the new value.
639
+ *
640
+ * Updates a pointer to a `NULL`-terminated string array to @new_strv and
641
+ * returns whether the value was changed.
642
+ *
643
+ * If @new_strv contains the same strings as the previous array, this function
644
+ * is a no-op. If @new_strv is different, it will be assigned to @strv_pointer
645
+ * and the previous array pointed to by @strv_pointer will be freed with
646
+ * [func@GLib.strfreev].
647
+ *
648
+ * If @new_strv does not replace the existing value, it will be freed with
649
+ * [func@GLib.strfreev], unless it is `NULL`.
650
+ *
651
+ * The contents of both string arrays are compared for equality before
652
+ * replacing the value. In the worst case this requires O(N) time.
653
+ *
654
+ * @strv_pointer must not be `NULL`, but can point to a `NULL` value.
655
+ * @new_strv must be `NULL` or a string array not already stored in
656
+ * @strv_pointer.
657
+ *
658
+ * Returns: true if the value of @strv_pointer changed, false otherwise
659
+ *
660
+ * Since: 2.90
661
+ */
662
+ GLIB_AVAILABLE_STATIC_INLINE_IN_2_90
663
+ static inline gboolean g_set_strv_take (char ***strv_pointer,
664
+ char **new_strv);
665
+
666
+ GLIB_AVAILABLE_STATIC_INLINE_IN_2_90
667
+ static inline gboolean
668
+ g_set_strv_take (char ***strv_pointer,
669
+ char **new_strv)
670
+ {
671
+ if (*strv_pointer == NULL && new_strv == NULL)
672
+ return FALSE;
673
+
674
+ G_GNUC_BEGIN_IGNORE_DEPRECATIONS
675
+ if (*strv_pointer && new_strv &&
676
+ g_strv_equal ((const char * const *)*strv_pointer,
677
+ (const char * const *)new_strv))
678
+ {
679
+ g_strfreev (new_strv);
680
+ return FALSE;
681
+ }
682
+ G_GNUC_END_IGNORE_DEPRECATIONS
683
+
684
+ g_strfreev (*strv_pointer);
685
+ *strv_pointer = new_strv;
686
+
687
+ return TRUE;
688
+ }
689
+
500
690
  G_END_DECLS
501
691
 
502
692
  #endif /* __G_STRFUNCS_H__ */
@@ -248,6 +248,15 @@ typedef enum {
248
248
  G_USER_DIRECTORY_TEMPLATES,
249
249
  G_USER_DIRECTORY_VIDEOS,
250
250
 
251
+ /**
252
+ * G_USER_DIRECTORY_PROJECTS:
253
+ *
254
+ * The user's Projects directory.
255
+ *
256
+ * Since: 2.90
257
+ */
258
+ G_USER_DIRECTORY_PROJECTS,
259
+
251
260
  G_USER_N_DIRECTORIES
252
261
  } GUserDirectory;
253
262