diff mde/gui/widget/miscContent.d @ 99:5de5810e3516

Implemented an editable TextContent widget; it's now possible to edit text options using the GUI. The widget supports moving the text entry-point using arrows and home/end, but there's no visual indicator or edit-point setting using the mouse.
author Diggory Hardy <diggory.hardy@gmail.com>
date Fri, 14 Nov 2008 12:44:32 +0000
parents 2a364c7d82c9
children 71f0f1f83620
line wrap: on
line diff
--- a/mde/gui/widget/miscContent.d	Wed Nov 12 13:18:51 2008 +0000
+++ b/mde/gui/widget/miscContent.d	Fri Nov 14 12:44:32 2008 +0000
@@ -16,6 +16,7 @@
 /** Some content widgets. */
 module mde.gui.widget.miscContent;
 
+import mde.gui.widget.textContent;
 import mde.gui.widget.Widget;
 import mde.gui.widget.TextWidget;
 import mde.gui.exception;
@@ -27,6 +28,8 @@
 IChildWidget editContent (IWidgetManager mgr, widgetID id, WidgetData data, IContent c) {
     if (cast(BoolContent) c)
         return new BoolContentWidget(mgr,id,data,c);
+    else if (cast(TextContent) c)
+	return new TextContentWidget(mgr,id,data,c);
     else        // generic uneditable option
         return new DisplayContentWidget(mgr,id,data,c);
 }