1 /* 2 * This file is part of gtkD. 3 * 4 * gtkD is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU Lesser General Public License 6 * as published by the Free Software Foundation; either version 3 7 * of the License, or (at your option) any later version, with 8 * some exceptions, please read the COPYING file. 9 * 10 * gtkD is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with gtkD; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA 18 */ 19 20 // generated automatically - do not change 21 // find conversion definition on APILookup.txt 22 // implement new conversion functionalities on the wrap.utils pakage 23 24 25 module gtk.IconInfo; 26 27 private import cairo.Surface; 28 private import gdk.RGBA; 29 private import gdk.Window; 30 private import gdkpixbuf.Pixbuf; 31 private import gio.AsyncResultIF; 32 private import gio.Cancellable; 33 private import glib.ConstructionException; 34 private import glib.ErrorG; 35 private import glib.GException; 36 private import glib.Str; 37 private import gobject.ObjectG; 38 private import gtk.IconTheme; 39 private import gtk.Style; 40 private import gtk.StyleContext; 41 private import gtk.c.functions; 42 public import gtk.c.types; 43 public import gtkc.gtktypes; 44 45 46 /** 47 * Contains information found when looking up an icon in 48 * an icon theme. 49 */ 50 public class IconInfo : ObjectG 51 { 52 /** the main Gtk struct */ 53 protected GtkIconInfo* gtkIconInfo; 54 55 /** Get the main Gtk struct */ 56 public GtkIconInfo* getIconInfoStruct(bool transferOwnership = false) 57 { 58 if (transferOwnership) 59 ownedRef = false; 60 return gtkIconInfo; 61 } 62 63 /** the main Gtk struct as a void* */ 64 protected override void* getStruct() 65 { 66 return cast(void*)gtkIconInfo; 67 } 68 69 protected override void setStruct(GObject* obj) 70 { 71 gtkIconInfo = cast(GtkIconInfo*)obj; 72 super.setStruct(obj); 73 } 74 75 /** 76 * Sets our main struct and passes it to the parent class. 77 */ 78 public this (GtkIconInfo* gtkIconInfo, bool ownedRef = false) 79 { 80 this.gtkIconInfo = gtkIconInfo; 81 super(cast(GObject*)gtkIconInfo, ownedRef); 82 } 83 84 85 /** */ 86 public static GType getType() 87 { 88 return gtk_icon_info_get_type(); 89 } 90 91 /** 92 * Creates a #GtkIconInfo for a #GdkPixbuf. 93 * 94 * Params: 95 * iconTheme = a #GtkIconTheme 96 * pixbuf = the pixbuf to wrap in a #GtkIconInfo 97 * 98 * Returns: a #GtkIconInfo 99 * 100 * Since: 2.14 101 * 102 * Throws: ConstructionException GTK+ fails to create the object. 103 */ 104 public this(IconTheme iconTheme, Pixbuf pixbuf) 105 { 106 auto p = gtk_icon_info_new_for_pixbuf((iconTheme is null) ? null : iconTheme.getIconThemeStruct(), (pixbuf is null) ? null : pixbuf.getPixbufStruct()); 107 108 if(p is null) 109 { 110 throw new ConstructionException("null returned by new_for_pixbuf"); 111 } 112 113 this(cast(GtkIconInfo*) p, true); 114 } 115 116 /** 117 * Make a copy of a #GtkIconInfo. 118 * 119 * Deprecated: Use g_object_ref() 120 * 121 * Returns: the new GtkIconInfo 122 * 123 * Since: 2.4 124 */ 125 public IconInfo copy() 126 { 127 auto p = gtk_icon_info_copy(gtkIconInfo); 128 129 if(p is null) 130 { 131 return null; 132 } 133 134 return ObjectG.getDObject!(IconInfo)(cast(GtkIconInfo*) p, true); 135 } 136 137 /** 138 * Free a #GtkIconInfo and associated information 139 * 140 * Deprecated: Use g_object_unref() 141 * 142 * Since: 2.4 143 */ 144 public void free() 145 { 146 gtk_icon_info_free(gtkIconInfo); 147 } 148 149 /** 150 * This function is deprecated and always returns %FALSE. 151 * 152 * Deprecated: Attachment points are deprecated 153 * 154 * Params: 155 * points = location to store pointer 156 * to an array of points, or %NULL free the array of points with g_free(). 157 * 158 * Returns: %FALSE 159 * 160 * Since: 2.4 161 */ 162 public bool getAttachPoints(out GdkPoint[] points) 163 { 164 GdkPoint* outpoints = null; 165 int nPoints; 166 167 auto p = gtk_icon_info_get_attach_points(gtkIconInfo, &outpoints, &nPoints) != 0; 168 169 points = outpoints[0 .. nPoints]; 170 171 return p; 172 } 173 174 /** 175 * Gets the base scale for the icon. The base scale is a scale 176 * for the icon that was specified by the icon theme creator. 177 * For instance an icon drawn for a high-dpi screen with window 178 * scale 2 for a base size of 32 will be 64 pixels tall and have 179 * a base scale of 2. 180 * 181 * Returns: the base scale 182 * 183 * Since: 3.10 184 */ 185 public int getBaseScale() 186 { 187 return gtk_icon_info_get_base_scale(gtkIconInfo); 188 } 189 190 /** 191 * Gets the base size for the icon. The base size 192 * is a size for the icon that was specified by 193 * the icon theme creator. This may be different 194 * than the actual size of image; an example of 195 * this is small emblem icons that can be attached 196 * to a larger icon. These icons will be given 197 * the same base size as the larger icons to which 198 * they are attached. 199 * 200 * Note that for scaled icons the base size does 201 * not include the base scale. 202 * 203 * Returns: the base size, or 0, if no base 204 * size is known for the icon. 205 * 206 * Since: 2.4 207 */ 208 public int getBaseSize() 209 { 210 return gtk_icon_info_get_base_size(gtkIconInfo); 211 } 212 213 /** 214 * Gets the built-in image for this icon, if any. To allow GTK+ to use 215 * built in icon images, you must pass the %GTK_ICON_LOOKUP_USE_BUILTIN 216 * to gtk_icon_theme_lookup_icon(). 217 * 218 * Deprecated: This function is deprecated, use 219 * gtk_icon_theme_add_resource_path() instead of builtin icons. 220 * 221 * Returns: the built-in image pixbuf, or %NULL. 222 * No extra reference is added to the returned pixbuf, so if 223 * you want to keep it around, you must use g_object_ref(). 224 * The returned image must not be modified. 225 * 226 * Since: 2.4 227 */ 228 public Pixbuf getBuiltinPixbuf() 229 { 230 auto p = gtk_icon_info_get_builtin_pixbuf(gtkIconInfo); 231 232 if(p is null) 233 { 234 return null; 235 } 236 237 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p); 238 } 239 240 /** 241 * This function is deprecated and always returns %NULL. 242 * 243 * Deprecated: Display names are deprecated 244 * 245 * Returns: %NULL 246 * 247 * Since: 2.4 248 */ 249 public string getDisplayName() 250 { 251 return Str.toString(gtk_icon_info_get_display_name(gtkIconInfo)); 252 } 253 254 /** 255 * This function is deprecated and always returns %FALSE. 256 * 257 * Deprecated: Embedded rectangles are deprecated 258 * 259 * Params: 260 * rectangle = #GdkRectangle in which to store embedded 261 * rectangle coordinates; coordinates are only stored 262 * when this function returns %TRUE. 263 * 264 * Returns: %FALSE 265 * 266 * Since: 2.4 267 */ 268 public bool getEmbeddedRect(out GdkRectangle rectangle) 269 { 270 return gtk_icon_info_get_embedded_rect(gtkIconInfo, &rectangle) != 0; 271 } 272 273 /** 274 * Gets the filename for the icon. If the %GTK_ICON_LOOKUP_USE_BUILTIN 275 * flag was passed to gtk_icon_theme_lookup_icon(), there may be no 276 * filename if a builtin icon is returned; in this case, you should 277 * use gtk_icon_info_get_builtin_pixbuf(). 278 * 279 * Returns: the filename for the icon, or %NULL 280 * if gtk_icon_info_get_builtin_pixbuf() should be used instead. 281 * The return value is owned by GTK+ and should not be modified 282 * or freed. 283 * 284 * Since: 2.4 285 */ 286 public string getFilename() 287 { 288 return Str.toString(gtk_icon_info_get_filename(gtkIconInfo)); 289 } 290 291 /** 292 * Checks if the icon is symbolic or not. This currently uses only 293 * the file name and not the file contents for determining this. 294 * This behaviour may change in the future. 295 * 296 * Returns: %TRUE if the icon is symbolic, %FALSE otherwise 297 * 298 * Since: 3.12 299 */ 300 public bool isSymbolic() 301 { 302 return gtk_icon_info_is_symbolic(gtkIconInfo) != 0; 303 } 304 305 /** 306 * Renders an icon previously looked up in an icon theme using 307 * gtk_icon_theme_lookup_icon(); the size will be based on the size 308 * passed to gtk_icon_theme_lookup_icon(). Note that the resulting 309 * pixbuf may not be exactly this size; an icon theme may have icons 310 * that differ slightly from their nominal sizes, and in addition GTK+ 311 * will avoid scaling icons that it considers sufficiently close to the 312 * requested size or for which the source image would have to be scaled 313 * up too far. (This maintains sharpness.). This behaviour can be changed 314 * by passing the %GTK_ICON_LOOKUP_FORCE_SIZE flag when obtaining 315 * the #GtkIconInfo. If this flag has been specified, the pixbuf 316 * returned by this function will be scaled to the exact size. 317 * 318 * Returns: the rendered icon; this may be a newly 319 * created icon or a new reference to an internal icon, so you must 320 * not modify the icon. Use g_object_unref() to release your reference 321 * to the icon. 322 * 323 * Since: 2.4 324 * 325 * Throws: GException on failure. 326 */ 327 public Pixbuf loadIcon() 328 { 329 GError* err = null; 330 331 auto p = gtk_icon_info_load_icon(gtkIconInfo, &err); 332 333 if (err !is null) 334 { 335 throw new GException( new ErrorG(err) ); 336 } 337 338 if(p is null) 339 { 340 return null; 341 } 342 343 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p, true); 344 } 345 346 /** 347 * Asynchronously load, render and scale an icon previously looked up 348 * from the icon theme using gtk_icon_theme_lookup_icon(). 349 * 350 * For more details, see gtk_icon_info_load_icon() which is the synchronous 351 * version of this call. 352 * 353 * Params: 354 * cancellable = optional #GCancellable object, %NULL to ignore 355 * callback = a #GAsyncReadyCallback to call when the 356 * request is satisfied 357 * userData = the data to pass to callback function 358 * 359 * Since: 3.8 360 */ 361 public void loadIconAsync(Cancellable cancellable, GAsyncReadyCallback callback, void* userData) 362 { 363 gtk_icon_info_load_icon_async(gtkIconInfo, (cancellable is null) ? null : cancellable.getCancellableStruct(), callback, userData); 364 } 365 366 /** 367 * Finishes an async icon load, see gtk_icon_info_load_icon_async(). 368 * 369 * Params: 370 * res = a #GAsyncResult 371 * 372 * Returns: the rendered icon; this may be a newly 373 * created icon or a new reference to an internal icon, so you must 374 * not modify the icon. Use g_object_unref() to release your reference 375 * to the icon. 376 * 377 * Since: 3.8 378 * 379 * Throws: GException on failure. 380 */ 381 public Pixbuf loadIconFinish(AsyncResultIF res) 382 { 383 GError* err = null; 384 385 auto p = gtk_icon_info_load_icon_finish(gtkIconInfo, (res is null) ? null : res.getAsyncResultStruct(), &err); 386 387 if (err !is null) 388 { 389 throw new GException( new ErrorG(err) ); 390 } 391 392 if(p is null) 393 { 394 return null; 395 } 396 397 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p, true); 398 } 399 400 /** 401 * Renders an icon previously looked up in an icon theme using 402 * gtk_icon_theme_lookup_icon(); the size will be based on the size 403 * passed to gtk_icon_theme_lookup_icon(). Note that the resulting 404 * surface may not be exactly this size; an icon theme may have icons 405 * that differ slightly from their nominal sizes, and in addition GTK+ 406 * will avoid scaling icons that it considers sufficiently close to the 407 * requested size or for which the source image would have to be scaled 408 * up too far. (This maintains sharpness.). This behaviour can be changed 409 * by passing the %GTK_ICON_LOOKUP_FORCE_SIZE flag when obtaining 410 * the #GtkIconInfo. If this flag has been specified, the pixbuf 411 * returned by this function will be scaled to the exact size. 412 * 413 * Params: 414 * forWindow = #GdkWindow to optimize drawing for, or %NULL 415 * 416 * Returns: the rendered icon; this may be a newly 417 * created icon or a new reference to an internal icon, so you must 418 * not modify the icon. Use cairo_surface_destroy() to release your 419 * reference to the icon. 420 * 421 * Since: 3.10 422 * 423 * Throws: GException on failure. 424 */ 425 public Surface loadSurface(Window forWindow) 426 { 427 GError* err = null; 428 429 auto p = gtk_icon_info_load_surface(gtkIconInfo, (forWindow is null) ? null : forWindow.getWindowStruct(), &err); 430 431 if (err !is null) 432 { 433 throw new GException( new ErrorG(err) ); 434 } 435 436 if(p is null) 437 { 438 return null; 439 } 440 441 return new Surface(cast(cairo_surface_t*) p); 442 } 443 444 /** 445 * Loads an icon, modifying it to match the system colours for the foreground, 446 * success, warning and error colors provided. If the icon is not a symbolic 447 * one, the function will return the result from gtk_icon_info_load_icon(). 448 * 449 * This allows loading symbolic icons that will match the system theme. 450 * 451 * Unless you are implementing a widget, you will want to use 452 * g_themed_icon_new_with_default_fallbacks() to load the icon. 453 * 454 * As implementation details, the icon loaded needs to be of SVG type, 455 * contain the “symbolic” term as the last component of the icon name, 456 * and use the “fg”, “success”, “warning” and “error” CSS styles in the 457 * SVG file itself. 458 * 459 * See the [Symbolic Icons Specification](http://www.freedesktop.org/wiki/SymbolicIcons) 460 * for more information about symbolic icons. 461 * 462 * Params: 463 * fg = a #GdkRGBA representing the foreground color of the icon 464 * successColor = a #GdkRGBA representing the warning color 465 * of the icon or %NULL to use the default color 466 * warningColor = a #GdkRGBA representing the warning color 467 * of the icon or %NULL to use the default color 468 * errorColor = a #GdkRGBA representing the error color 469 * of the icon or %NULL to use the default color (allow-none) 470 * wasSymbolic = a #gboolean, returns whether the 471 * loaded icon was a symbolic one and whether the @fg color was 472 * applied to it. 473 * 474 * Returns: a #GdkPixbuf representing the loaded icon 475 * 476 * Since: 3.0 477 * 478 * Throws: GException on failure. 479 */ 480 public Pixbuf loadSymbolic(RGBA fg, RGBA successColor, RGBA warningColor, RGBA errorColor, out bool wasSymbolic) 481 { 482 int outwasSymbolic; 483 GError* err = null; 484 485 auto p = gtk_icon_info_load_symbolic(gtkIconInfo, (fg is null) ? null : fg.getRGBAStruct(), (successColor is null) ? null : successColor.getRGBAStruct(), (warningColor is null) ? null : warningColor.getRGBAStruct(), (errorColor is null) ? null : errorColor.getRGBAStruct(), &outwasSymbolic, &err); 486 487 if (err !is null) 488 { 489 throw new GException( new ErrorG(err) ); 490 } 491 492 wasSymbolic = (outwasSymbolic == 1); 493 494 if(p is null) 495 { 496 return null; 497 } 498 499 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p, true); 500 } 501 502 /** 503 * Asynchronously load, render and scale a symbolic icon previously looked up 504 * from the icon theme using gtk_icon_theme_lookup_icon(). 505 * 506 * For more details, see gtk_icon_info_load_symbolic() which is the synchronous 507 * version of this call. 508 * 509 * Params: 510 * fg = a #GdkRGBA representing the foreground color of the icon 511 * successColor = a #GdkRGBA representing the warning color 512 * of the icon or %NULL to use the default color 513 * warningColor = a #GdkRGBA representing the warning color 514 * of the icon or %NULL to use the default color 515 * errorColor = a #GdkRGBA representing the error color 516 * of the icon or %NULL to use the default color (allow-none) 517 * cancellable = optional #GCancellable object, 518 * %NULL to ignore 519 * callback = a #GAsyncReadyCallback to call when the 520 * request is satisfied 521 * userData = the data to pass to callback function 522 * 523 * Since: 3.8 524 */ 525 public void loadSymbolicAsync(RGBA fg, RGBA successColor, RGBA warningColor, RGBA errorColor, Cancellable cancellable, GAsyncReadyCallback callback, void* userData) 526 { 527 gtk_icon_info_load_symbolic_async(gtkIconInfo, (fg is null) ? null : fg.getRGBAStruct(), (successColor is null) ? null : successColor.getRGBAStruct(), (warningColor is null) ? null : warningColor.getRGBAStruct(), (errorColor is null) ? null : errorColor.getRGBAStruct(), (cancellable is null) ? null : cancellable.getCancellableStruct(), callback, userData); 528 } 529 530 /** 531 * Finishes an async icon load, see gtk_icon_info_load_symbolic_async(). 532 * 533 * Params: 534 * res = a #GAsyncResult 535 * wasSymbolic = a #gboolean, returns whether the 536 * loaded icon was a symbolic one and whether the @fg color was 537 * applied to it. 538 * 539 * Returns: the rendered icon; this may be a newly 540 * created icon or a new reference to an internal icon, so you must 541 * not modify the icon. Use g_object_unref() to release your reference 542 * to the icon. 543 * 544 * Since: 3.8 545 * 546 * Throws: GException on failure. 547 */ 548 public Pixbuf loadSymbolicFinish(AsyncResultIF res, out bool wasSymbolic) 549 { 550 int outwasSymbolic; 551 GError* err = null; 552 553 auto p = gtk_icon_info_load_symbolic_finish(gtkIconInfo, (res is null) ? null : res.getAsyncResultStruct(), &outwasSymbolic, &err); 554 555 if (err !is null) 556 { 557 throw new GException( new ErrorG(err) ); 558 } 559 560 wasSymbolic = (outwasSymbolic == 1); 561 562 if(p is null) 563 { 564 return null; 565 } 566 567 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p, true); 568 } 569 570 /** 571 * Loads an icon, modifying it to match the system colors for the foreground, 572 * success, warning and error colors provided. If the icon is not a symbolic 573 * one, the function will return the result from gtk_icon_info_load_icon(). 574 * This function uses the regular foreground color and the symbolic colors 575 * with the names “success_color”, “warning_color” and “error_color” from 576 * the context. 577 * 578 * This allows loading symbolic icons that will match the system theme. 579 * 580 * See gtk_icon_info_load_symbolic() for more details. 581 * 582 * Params: 583 * context = a #GtkStyleContext 584 * wasSymbolic = a #gboolean, returns whether the 585 * loaded icon was a symbolic one and whether the @fg color was 586 * applied to it. 587 * 588 * Returns: a #GdkPixbuf representing the loaded icon 589 * 590 * Since: 3.0 591 * 592 * Throws: GException on failure. 593 */ 594 public Pixbuf loadSymbolicForContext(StyleContext context, out bool wasSymbolic) 595 { 596 int outwasSymbolic; 597 GError* err = null; 598 599 auto p = gtk_icon_info_load_symbolic_for_context(gtkIconInfo, (context is null) ? null : context.getStyleContextStruct(), &outwasSymbolic, &err); 600 601 if (err !is null) 602 { 603 throw new GException( new ErrorG(err) ); 604 } 605 606 wasSymbolic = (outwasSymbolic == 1); 607 608 if(p is null) 609 { 610 return null; 611 } 612 613 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p, true); 614 } 615 616 /** 617 * Asynchronously load, render and scale a symbolic icon previously 618 * looked up from the icon theme using gtk_icon_theme_lookup_icon(). 619 * 620 * For more details, see gtk_icon_info_load_symbolic_for_context() 621 * which is the synchronous version of this call. 622 * 623 * Params: 624 * context = a #GtkStyleContext 625 * cancellable = optional #GCancellable object, 626 * %NULL to ignore 627 * callback = a #GAsyncReadyCallback to call when the 628 * request is satisfied 629 * userData = the data to pass to callback function 630 * 631 * Since: 3.8 632 */ 633 public void loadSymbolicForContextAsync(StyleContext context, Cancellable cancellable, GAsyncReadyCallback callback, void* userData) 634 { 635 gtk_icon_info_load_symbolic_for_context_async(gtkIconInfo, (context is null) ? null : context.getStyleContextStruct(), (cancellable is null) ? null : cancellable.getCancellableStruct(), callback, userData); 636 } 637 638 /** 639 * Finishes an async icon load, see gtk_icon_info_load_symbolic_for_context_async(). 640 * 641 * Params: 642 * res = a #GAsyncResult 643 * wasSymbolic = a #gboolean, returns whether the 644 * loaded icon was a symbolic one and whether the @fg color was 645 * applied to it. 646 * 647 * Returns: the rendered icon; this may be a newly 648 * created icon or a new reference to an internal icon, so you must 649 * not modify the icon. Use g_object_unref() to release your reference 650 * to the icon. 651 * 652 * Since: 3.8 653 * 654 * Throws: GException on failure. 655 */ 656 public Pixbuf loadSymbolicForContextFinish(AsyncResultIF res, out bool wasSymbolic) 657 { 658 int outwasSymbolic; 659 GError* err = null; 660 661 auto p = gtk_icon_info_load_symbolic_for_context_finish(gtkIconInfo, (res is null) ? null : res.getAsyncResultStruct(), &outwasSymbolic, &err); 662 663 if (err !is null) 664 { 665 throw new GException( new ErrorG(err) ); 666 } 667 668 wasSymbolic = (outwasSymbolic == 1); 669 670 if(p is null) 671 { 672 return null; 673 } 674 675 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p, true); 676 } 677 678 /** 679 * Loads an icon, modifying it to match the system colours for the foreground, 680 * success, warning and error colors provided. If the icon is not a symbolic 681 * one, the function will return the result from gtk_icon_info_load_icon(). 682 * 683 * This allows loading symbolic icons that will match the system theme. 684 * 685 * See gtk_icon_info_load_symbolic() for more details. 686 * 687 * Deprecated: Use gtk_icon_info_load_symbolic_for_context() instead 688 * 689 * Params: 690 * style = a #GtkStyle to take the colors from 691 * state = the widget state to use for colors 692 * wasSymbolic = a #gboolean, returns whether the 693 * loaded icon was a symbolic one and whether the @fg color was 694 * applied to it. 695 * 696 * Returns: a #GdkPixbuf representing the loaded icon 697 * 698 * Since: 3.0 699 * 700 * Throws: GException on failure. 701 */ 702 public Pixbuf loadSymbolicForStyle(Style style, GtkStateType state, out bool wasSymbolic) 703 { 704 int outwasSymbolic; 705 GError* err = null; 706 707 auto p = gtk_icon_info_load_symbolic_for_style(gtkIconInfo, (style is null) ? null : style.getStyleStruct(), state, &outwasSymbolic, &err); 708 709 if (err !is null) 710 { 711 throw new GException( new ErrorG(err) ); 712 } 713 714 wasSymbolic = (outwasSymbolic == 1); 715 716 if(p is null) 717 { 718 return null; 719 } 720 721 return ObjectG.getDObject!(Pixbuf)(cast(GdkPixbuf*) p, true); 722 } 723 724 /** 725 * Sets whether the coordinates returned by gtk_icon_info_get_embedded_rect() 726 * and gtk_icon_info_get_attach_points() should be returned in their 727 * original form as specified in the icon theme, instead of scaled 728 * appropriately for the pixbuf returned by gtk_icon_info_load_icon(). 729 * 730 * Raw coordinates are somewhat strange; they are specified to be with 731 * respect to the unscaled pixmap for PNG and XPM icons, but for SVG 732 * icons, they are in a 1000x1000 coordinate space that is scaled 733 * to the final size of the icon. You can determine if the icon is an SVG 734 * icon by using gtk_icon_info_get_filename(), and seeing if it is non-%NULL 735 * and ends in “.svg”. 736 * 737 * This function is provided primarily to allow compatibility wrappers 738 * for older API's, and is not expected to be useful for applications. 739 * 740 * Deprecated: Embedded rectangles and attachment points are deprecated 741 * 742 * Params: 743 * rawCoordinates = whether the coordinates of embedded rectangles 744 * and attached points should be returned in their original 745 * (unscaled) form. 746 * 747 * Since: 2.4 748 */ 749 public void setRawCoordinates(bool rawCoordinates) 750 { 751 gtk_icon_info_set_raw_coordinates(gtkIconInfo, rawCoordinates); 752 } 753 }