Show
Ignore:
Timestamp:
05/04/08 18:12:38 (8 months ago)
Author:
Frank Benoit <benoit@tionex.de>
branch:
default
Message:

reverted the char[] to String and use the an alias.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • dwt/graphics/GC.d

    r197 r212  
    582582        } else { 
    583583            chars = new wchar[OS.LF_FACESIZE]; 
    584             char[] bytes = logFont.lfFaceName; 
     584            String bytes = logFont.lfFaceName; 
    585585            OS.MultiByteToWideChar (OS.CP_ACP, OS.MB_PRECOMPOSED, bytes.ptr, bytes.length, chars, chars.length); 
    586586        } 
     
    590590            index++; 
    591591        } 
    592         char[] name = WCHARsToStr( chars[ 0 .. index ] ); 
     592        String name = WCHARsToStr( chars[ 0 .. index ] ); 
    593593        if (Compatibility.equalsIgnoreCase(name, "Courier")) { //$NON-NLS-1$ 
    594594            name = "Courier New"; //$NON-NLS-1$ 
     
    20812081 * </ul> 
    20822082 */ 
    2083 public void drawString (char[] string, int x, int y) { 
     2083public void drawString (String string, int x, int y) { 
    20842084    drawString(string, x, y, false); 
    20852085} 
     
    21052105 * </ul> 
    21062106 */ 
    2107 public void drawString (char[] string, int x, int y, bool isTransparent) { 
     2107public void drawString (String string, int x, int y, bool isTransparent) { 
    21082108    if (handle is null) DWT.error(DWT.ERROR_GRAPHIC_DISPOSED); 
    21092109    if (string is null) DWT.error(DWT.ERROR_NULL_ARGUMENT); 
     
    22372237 * </ul> 
    22382238 */ 
    2239 public void drawText (char[] string, int x, int y) { 
     2239public void drawText (String string, int x, int y) { 
    22402240    drawText(string, x, y, DWT.DRAW_DELIMITER | DWT.DRAW_TAB); 
    22412241} 
     
    22612261 * </ul> 
    22622262 */ 
    2263 public void drawText (char[] string, int x, int y, bool isTransparent) { 
     2263public void drawText (String string, int x, int y, bool isTransparent) { 
    22642264    int flags = DWT.DRAW_DELIMITER | DWT.DRAW_TAB; 
    22652265    if (isTransparent) flags |= DWT.DRAW_TRANSPARENT; 
     
    23012301 * </ul> 
    23022302 */ 
    2303 public void drawText (char[] string, int x, int y, int flags) { 
     2303public void drawText (String string, int x, int y, int flags) { 
    23042304    if (handle is null) DWT.error(DWT.ERROR_GRAPHIC_DISPOSED); 
    23052305    if (string is null) DWT.error(DWT.ERROR_NULL_ARGUMENT); 
     
    46874687 * </ul> 
    46884688 */ 
    4689 public Point stringExtent(char[] string) { 
     4689public Point stringExtent(String string) { 
    46904690    if (handle is null) DWT.error(DWT.ERROR_GRAPHIC_DISPOSED); 
    46914691    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    47454745 * </ul> 
    47464746 */ 
    4747 public Point textExtent(char[] string) { 
     4747public Point textExtent(String string) { 
    47484748    return textExtent(string, DWT.DRAW_DELIMITER | DWT.DRAW_TAB); 
    47494749} 
     
    47804780 * </ul> 
    47814781 */ 
    4782 public Point textExtent(char[] string, int flags) { 
     4782public Point textExtent(String string, int flags) { 
    47834783    if (handle is null) DWT.error(DWT.ERROR_GRAPHIC_DISPOSED); 
    47844784    if (string is null) DWT.error (DWT.ERROR_NULL_ARGUMENT); 
     
    48314831 * @return a string representation of the receiver 
    48324832 */ 
    4833 override public char[] toString () { 
     4833override public String toString () { 
    48344834    if (isDisposed()) return "GC {*DISPOSED*}"; 
    48354835    return Format( "GC {{{}}", handle );