summaryrefslogtreecommitdiff
path: root/iup
diff options
context:
space:
mode:
authorNicolas "Pixel" Noble <pixel@nobis-crew.org>2010-09-10 00:30:10 +0200
committerNicolas "Pixel" Noble <pixel@nobis-crew.org>2010-09-10 00:30:10 +0200
commitc238f727943fd3b4b8a46be816da54e10aca35d2 (patch)
treefe2a59cfb1e055bec02dd9744ee984a96a021650 /iup
parent6646ed5da54049c3837f4dcc71b5d2415fdc412b (diff)
The User object may have children now, and adding the CLEANOUT boolean to the formattag bulk system.
Diffstat (limited to 'iup')
-rwxr-xr-xiup/src/iup_text.c6
-rwxr-xr-xiup/src/iup_user.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/iup/src/iup_text.c b/iup/src/iup_text.c
index 06c6915..6042970 100755
--- a/iup/src/iup_text.c
+++ b/iup/src/iup_text.c
@@ -116,6 +116,12 @@ int iupTextSetAddFormatTagHandleAttrib(Ihandle* ih, const char* value)
{
Ihandle* child = NULL;
void* state = iupdrvTextAddFormatTagStartBulk(ih);
+ char* cleanout = iupAttribGet(formattag, "CLEANOUT");
+ if (cleanout && iupStrBoolean(cleanout))
+ {
+ iupAttribSetStr(ih, "SELECTION", "ALL");
+ iupAttribSetStr(ih, "REMOVEFORMATTING", NULL);
+ }
for (child = IupGetNextChild(formattag, NULL); child; child = IupGetNextChild(formattag, child))
iupdrvTextAddFormatTag(ih, child, 1);
iupdrvTextAddFormatTagStopBulk(ih, state);
diff --git a/iup/src/iup_user.c b/iup/src/iup_user.c
index 842f436..90a9fb7 100755
--- a/iup/src/iup_user.c
+++ b/iup/src/iup_user.c
@@ -32,7 +32,7 @@ Iclass* iupUserGetClass(void)
ic->name = "user";
ic->format = NULL; /* no parameters */
ic->nativetype = IUP_TYPEVOID;
- ic->childtype = IUP_CHILDNONE;
+ ic->childtype = IUP_CHILDMANY;
ic->is_interactive = 0;
iupClassRegisterAttribute(ic, "CLEARATTRIBUTES", NULL, iUserSetClearAttributesAttrib, NULL, NULL, IUPAF_NOT_MAPPED|IUPAF_NO_INHERIT);