Changeset 480 for trunk/src/gdk/Font.d
- Timestamp:
- 03/25/08 18:16:02 (8 months ago)
- Files:
-
- trunk/src/gdk/Font.d (modified) (16 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/src/gdk/Font.d
r429 r480 53 53 * module aliases: 54 54 * local aliases: 55 * overrides: 55 56 */ 56 57 … … 240 241 * Create and loads a font 241 242 */ 242 public this( char[]fontName)243 public this(string fontName) 243 244 { 244 245 this(gdk_font_load(Str.toStringz(fontName))); … … 258 259 * Returns: a GdkFont, or NULL if the font could not be loaded. 259 260 */ 260 public static Font load( char[]fontName)261 public static Font load(string fontName) 261 262 { 262 263 // GdkFont* gdk_font_load (const gchar *font_name); … … 282 283 * Returns: a GdkFont, or NULL if the font could not be loaded. 283 284 */ 284 public static Font loadForDisplay(Display display, char[]fontName)285 public static Font loadForDisplay(Display display, string fontName) 285 286 { 286 287 // GdkFont* gdk_font_load_for_display (GdkDisplay *display, const gchar *font_name); … … 305 306 * Returns: a GdkFont, or NULL if the fontset could not be loaded. 306 307 */ 307 public static Font fontsetLoad( char[]fontsetName)308 public static Font fontsetLoad(string fontsetName) 308 309 { 309 310 // GdkFont* gdk_fontset_load (const gchar *fontset_name); … … 330 331 * Returns: a GdkFont, or NULL if the fontset could not be loaded. 331 332 */ 332 public static Font fontsetLoadForDisplay(Display display, char[]fontsetName)333 public static Font fontsetLoadForDisplay(Display display, string fontsetName) 333 334 { 334 335 // GdkFont* gdk_fontset_load_for_display (GdkDisplay *display, const gchar *fontset_name); … … 481 482 * descent = the descent of the string. 482 483 */ 483 public void stringExtents( char[]string, int* lbearing, int* rbearing, int* width, int* ascent, int* descent)484 public void stringExtents(string string, int* lbearing, int* rbearing, int* width, int* ascent, int* descent) 484 485 { 485 486 // void gdk_string_extents (GdkFont *font, const gchar *string, gint *lbearing, gint *rbearing, gint *width, gint *ascent, gint *descent); … … 502 503 * descent = the descent of the string. 503 504 */ 504 public void textExtents( char[]text, int textLength, int* lbearing, int* rbearing, int* width, int* ascent, int* descent)505 public void textExtents(string text, int textLength, int* lbearing, int* rbearing, int* width, int* ascent, int* descent) 505 506 { 506 507 // void gdk_text_extents (GdkFont *font, const gchar *text, gint text_length, gint *lbearing, gint *rbearing, gint *width, gint *ascent, gint *descent); … … 538 539 * Returns: the width of the string in pixels. 539 540 */ 540 public int stringWidth( char[]string)541 public int stringWidth(string string) 541 542 { 542 543 // gint gdk_string_width (GdkFont *font, const gchar *string); … … 553 554 * Returns: the width of the string in pixels. 554 555 */ 555 public int textWidth( char[]text, int textLength)556 public int textWidth(string text, int textLength) 556 557 { 557 558 // gint gdk_text_width (GdkFont *font, const gchar *text, gint text_length); … … 615 616 * Returns: the right bearing of the string in pixels. 616 617 */ 617 public int stringMeasure( char[]string)618 public int stringMeasure(string string) 618 619 { 619 620 // gint gdk_string_measure (GdkFont *font, const gchar *string); … … 634 635 * Returns: the right bearing of the string in pixels. 635 636 */ 636 public int textMeasure( char[]text, int textLength)637 public int textMeasure(string text, int textLength) 637 638 { 638 639 // gint gdk_text_measure (GdkFont *font, const gchar *text, gint text_length); … … 668 669 * Returns: the height of the string in pixels. 669 670 */ 670 public int stringHeight( char[]string)671 public int stringHeight(string string) 671 672 { 672 673 // gint gdk_string_height (GdkFont *font, const gchar *string); … … 686 687 * Returns: the height of the string in pixels. 687 688 */ 688 public int textHeight( char[]text, int textLength)689 public int textHeight(string text, int textLength) 689 690 { 690 691 // gint gdk_text_height (GdkFont *font, const gchar *text, gint text_length); … … 719 720 * Returns: the multi-byte string corresponding to src, or NULL if theconversion failed. The returned string should be freed with g_free() when nolonger needed. 720 721 */ 721 public static char[]wcstombs(GdkWChar* src)722 public static string wcstombs(GdkWChar* src) 722 723 { 723 724 // gchar* gdk_wcstombs (const GdkWChar *src); 724 return Str.toString(gdk_wcstombs(src)) .dup;725 return Str.toString(gdk_wcstombs(src)); 725 726 } 726 727 … … 737 738 * Returns: the number of wide characters written into dest, or -1 if the conversion failed. 738 739 */ 739 public static int mbstowcs(GdkWChar* dest, char[]src, int destMax)740 public static int mbstowcs(GdkWChar* dest, string src, int destMax) 740 741 { 741 742 // gint gdk_mbstowcs (GdkWChar *dest, const gchar *src, gint dest_max);
