Changeset 238:380bad9f6852 for dwt/graphics/Font.d
- Timestamp:
- 05/04/08 18:42:55 (4 years ago)
- Files:
-
- dwt/graphics/Font.d (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
dwt/graphics/Font.d
r216 r238 12 12 *******************************************************************************/ 13 13 module dwt.graphics.Font; 14 15 import dwt.dwthelper.utils; 14 16 15 17 … … 137 139 * </ul> 138 140 */ 139 public this(Device device, char[]name, int height, int style) {141 public this(Device device, String name, int height, int style) { 140 142 if (device is null) device = Device.getDevice(); 141 143 if (device is null) DWT.error(DWT.ERROR_NULL_ARGUMENT); … … 144 146 } 145 147 146 /*public*/ this(Device device, char[]name, float height, int style) {148 /*public*/ this(Device device, String name, float height, int style) { 147 149 if (device is null) device = Device.getDevice(); 148 150 if (device is null) DWT.error(DWT.ERROR_NULL_ARGUMENT); … … 200 202 201 203 auto family = OS.pango_font_description_get_family(handle); 202 char[]name = fromStringz( family );204 String name = fromStringz( family ); 203 205 float height = cast(float)OS.pango_font_description_get_size(handle) / OS.PANGO_SCALE; 204 206 int pangoStyle = OS.pango_font_description_get_style(handle); … … 253 255 } 254 256 255 void init_(Device device, char[] name, float height, int style, char[]fontString) {257 void init_(Device device, String name, float height, int style, String fontString) { 256 258 if (name is null) DWT.error(DWT.ERROR_NULL_ARGUMENT); 257 259 if (height < 0) DWT.error(DWT.ERROR_INVALID_ARGUMENT); … … 297 299 * @return a string representation of the receiver 298 300 */ 299 public char[]toString () {301 public String toString () { 300 302 if (isDisposed()) return "Font {*DISPOSED*}"; 301 303 return Format( "Font {{{}}", handle );
