diff dwt/custom/StyledTextRenderer.d @ 212:ab60f3309436

reverted the char[] to String and use the an alias.
author Frank Benoit <benoit@tionex.de>
date Mon, 05 May 2008 00:12:38 +0200
parents a5afe31f5cdd
children 36f5cb12e1a2
line wrap: on
line diff
--- a/dwt/custom/StyledTextRenderer.d	Sat Apr 26 10:01:48 2008 +0200
+++ b/dwt/custom/StyledTextRenderer.d	Mon May 05 00:12:38 2008 +0200
@@ -359,11 +359,11 @@
     }
     Font font = style.font;
     if (font !is null) gc.setFont(font);
-    char[] string = "";
+    String string = "";
     int type = bullet.type & (ST.BULLET_DOT|ST.BULLET_NUMBER|ST.BULLET_LETTER_LOWER|ST.BULLET_LETTER_UPPER);
     switch (type) {
         case ST.BULLET_DOT: string = "\u2022"; break;
-        case ST.BULLET_NUMBER: string = to!(char[])(index); break;
+        case ST.BULLET_NUMBER: string = to!(String)(index); break;
         case ST.BULLET_LETTER_LOWER: string = [cast(char) (index % 26 + 97)]; break;
         case ST.BULLET_LETTER_UPPER: string = [cast(char) (index % 26 + 65)]; break;
         default:
@@ -384,7 +384,7 @@
 }
 int drawLine(int lineIndex, int paintX, int paintY, GC gc, Color widgetBackground, Color widgetForeground) {
     TextLayout layout = getTextLayout(lineIndex);
-    char[] line = content.getLine(lineIndex);
+    String line = content.getLine(lineIndex);
     int lineOffset = content.getOffsetAtLine(lineIndex);
     int lineLength = line.length;
     Point selection = styledText.getSelection();
@@ -731,7 +731,7 @@
         }
     }
     if (layout is null) layout = new TextLayout(device);
-    char[] line = content.getLine(lineIndex);
+    String line = content.getLine(lineIndex);
     int lineOffset = content.getOffsetAtLine(lineIndex);
     int[] segments = null;
     int indent = 0;