1 /***************************************************************************
3 TextEditor.mcc - Textediting MUI Custom Class
4 Copyright (C) 1997-2000 Allan Odgaard
5 Copyright (C) 2005 by TextEditor.mcc Open Source Team
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Lesser General Public
9 License as published by the Free Software Foundation; either
10 version 2.1 of the License, or (at your option) any later version.
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Lesser General Public License for more details.
17 TextEditor class Support Site: http://www.sf.net/projects/texteditor-mcc
21 ***************************************************************************/
25 #include <clib/alib_protos.h>
26 #include <devices/inputevent.h>
27 #include <libraries/asl.h>
28 #include <libraries/mui.h>
29 #include <proto/exec.h>
30 #include <proto/intuition.h>
31 #include <proto/muimaster.h>
38 #define MUIM_Mccprefs_RegisterGadget 0x80424828 // V20
45 #include "TextEditor_mcc.h"
47 char *FunctionName (UWORD func
)
54 name
= GetStr(MSG_Function_Up
);
58 name
= GetStr(MSG_Function_Down
);
62 name
= GetStr(MSG_Function_Left
);
66 name
= GetStr(MSG_Function_Right
);
70 name
= GetStr(MSG_Function_PrvPage
);
74 name
= GetStr(MSG_Function_NxtPage
);
78 name
= GetStr(MSG_Function_BOL
);
82 name
= GetStr(MSG_Function_EOL
);
86 name
= GetStr(MSG_Function_Top
);
90 name
= GetStr(MSG_Function_Bottom
);
94 name
= GetStr(MSG_Function_PrvWord
);
98 name
= GetStr(MSG_Function_NxtWord
);
102 name
= GetStr(MSG_Function_PrvPara
);
106 name
= GetStr(MSG_Function_NxtPara
);
109 case mPreviousSentence
:
110 name
= GetStr(MSG_Function_PrvSent
);
114 name
= GetStr(MSG_Function_NxtSent
);
118 name
= GetStr(MSG_Function_SuggestSpelling
);
122 name
= GetStr(MSG_Function_Backspace
);
126 name
= GetStr(MSG_Function_Delete
);
130 name
= GetStr(MSG_Function_Return
);
134 name
= GetStr(MSG_Function_Tab
);
138 name
= GetStr(MSG_Function_Cut
);
142 name
= GetStr(MSG_Function_Copy
);
146 name
= GetStr(MSG_Function_Paste
);
150 name
= GetStr(MSG_Function_Undo
);
154 name
= GetStr(MSG_Function_Redo
);
158 name
= GetStr(MSG_Function_DelEOL
);
162 name
= GetStr(MSG_Function_DelBOL
);
166 name
= GetStr(MSG_Function_DelEOW
);
170 name
= GetStr(MSG_Function_DelBOW
);
174 name
= GetStr(MSG_Function_DelLine
);
178 name
= GetStr(MSG_Function_NextGadget
);
182 name
= GetStr(MSG_Function_GotoBookmark1
);
186 name
= GetStr(MSG_Function_GotoBookmark2
);
190 name
= GetStr(MSG_Function_GotoBookmark3
);
194 name
= GetStr(MSG_Function_SetBookmark1
);
198 name
= GetStr(MSG_Function_SetBookmark2
);
202 name
= GetStr(MSG_Function_SetBookmark3
);
211 #define ARRAY_SIZE(X) (sizeof(X)/sizeof(X[0]))
212 /* compile time assert to cause a linker error. DO NOT CHANGE! */
213 void __FAIL_ON_ME(void);
214 #define _ASSERT(EXP) ((void) ((EXP) ? 0 : __FAIL_ON_ME()))
216 static Object
*PrefsObject(struct InstData_MCP
*data
)
218 static const void *titles
[] = {
220 MSG_Page_Keybindings
,
221 MSG_Page_SpellChecker
,
224 static const void *functions
[] = {
229 MSG_Function_PrvPage
,
230 MSG_Function_NxtPage
,
235 MSG_Function_PrvWord
,
236 MSG_Function_NxtWord
,
237 MSG_Function_PrvPara
,
238 MSG_Function_NxtPara
,
239 MSG_Function_PrvSent
,
240 MSG_Function_NxtSent
,
241 MSG_Function_SuggestSpelling
,
242 MSG_Function_Backspace
,
255 MSG_Function_NextGadget
,
256 MSG_Function_GotoBookmark1
,
257 MSG_Function_GotoBookmark2
,
258 MSG_Function_GotoBookmark3
,
259 MSG_Function_SetBookmark1
,
260 MSG_Function_SetBookmark2
,
261 MSG_Function_SetBookmark3
,
264 static const void *cycleentries
[] = {
272 _ASSERT( ARRAY_SIZE(data
->gTitles
) == (ARRAY_SIZE(titles
)+1) );
273 for(i
=0; i
<ARRAY_SIZE(titles
); i
++)
274 data
->gTitles
[i
] = GetStr((APTR
)titles
[i
]);
275 data
->gTitles
[ARRAY_SIZE(titles
)] = NULL
;
277 _ASSERT( ARRAY_SIZE(data
->functions
) == (ARRAY_SIZE(functions
)+1) );
278 for(i
=0; i
<ARRAY_SIZE(functions
); i
++)
279 data
->functions
[i
] = GetStr((APTR
)functions
[i
]);
280 data
->functions
[ARRAY_SIZE(functions
)] = NULL
;
282 _ASSERT( ARRAY_SIZE(data
->execution
) == 3 );
283 data
->execution
[0] = GetStr(MSG_Execution_CLI
);
284 data
->execution
[1] = GetStr(MSG_Execution_ARexx
);
285 data
->execution
[2] = NULL
;
287 _ASSERT( ARRAY_SIZE(data
->cycleentries
) == (ARRAY_SIZE(cycleentries
)+1) );
288 for(i
=0; i
<ARRAY_SIZE(cycleentries
); i
++)
289 data
->cycleentries
[i
] = GetStr((APTR
)cycleentries
[i
]);
290 data
->cycleentries
[ARRAY_SIZE(cycleentries
)] = NULL
;
292 data
->obj
= CreatePrefsGroup(data
);
295 set(data
->normalfont
, MUIA_String_AdvanceOnCR
, TRUE
);
296 set(data
->fixedfont
, MUIA_String_AdvanceOnCR
, TRUE
);
298 DoMethod(data
->blockqual
, MUIM_MultiSet
, MUIA_CycleChain
, TRUE
,
299 data
->blockqual
, data
->tabsize
, data
->smooth
,
300 data
->normalfont
, data
->fixedfont
, data
->textcolor
, data
->frame
,
301 data
->highlightcolor
, data
->background
, data
->cursorcolor
,
302 data
->markedcolor
, data
->cursorwidth
, data
->deletekey
,
303 data
->blinkspeed
, data
->suggestcmd
, data
->lookupcmd
,
304 data
->typenspell
, data
->undosize
, data
->LookupExeType
,
305 data
->SuggestExeType
, data
->CheckWord
, data
->insertkey
,
306 data
->separatorshadow
, data
->separatorshine
, NULL
);
312 ULONG
New(REG(a0
, struct IClass
*cl
), REG(a2
, Object
*obj
), REG(a1
, struct opSet
*msg
))
314 if((obj
= (Object
*)DoSuperMethodA(cl
, obj
, (Msg
)msg
)))
316 struct InstData_MCP
*data
= INST_DATA(cl
, obj
);
318 // create the main prefs object
319 Object
*prefsobject
= PrefsObject(data
);
321 if((data
->CfgObj
= prefsobject
))
323 DoMethod(obj
, OM_ADDMEMBER
, prefsobject
);
325 if(MUIMasterBase
->lib_Version
>= 20)
327 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->LookupExeType
, MUICFG_TextEditor_LookupCmd
, 1, GetStr(MSG_Label_LookupCmd
));
328 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->lookupcmd
, MUICFG_TextEditor_LookupCmd
, 1, GetStr(MSG_Label_LookupCmd
));
329 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->SuggestExeType
, MUICFG_TextEditor_SuggestCmd
, 1, GetStr(MSG_Label_SuggestCmd
));
330 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->suggestcmd
, MUICFG_TextEditor_SuggestCmd
, 1, GetStr(MSG_Label_SuggestCmd
));
331 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->keybindings
, MUICFG_TextEditor_Keybindings
, 1, GetStr(MSG_Page_Keybindings
));
332 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->frame
, MUICFG_TextEditor_Frame
, 1, GetStr(MSG_Label_Frame
));
333 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->background
, MUICFG_TextEditor_Background
, 1, GetStr(MSG_Label_Background
));
334 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->blinkspeed
, MUICFG_TextEditor_BlinkSpeed
, 1, GetStr(MSG_Label_BlinkSpeed
));
335 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->blockqual
, MUICFG_TextEditor_BlockQual
, 1, GetStr(MSG_Label_BlkQual
));
336 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->cursorcolor
, MUICFG_TextEditor_CursorColor
, 1, GetStr(MSG_Label_Cursor
));
337 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->cursorwidth
, MUICFG_TextEditor_CursorWidth
, 1, GetStr(MSG_Label_Width
));
338 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->fixedfont
, MUICFG_TextEditor_FixedFont
, 1, GetStr(MSG_Label_Fixed
));
339 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->highlightcolor
, MUICFG_TextEditor_HighlightColor
, 1, GetStr(MSG_Label_Highlight
));
340 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->markedcolor
, MUICFG_TextEditor_MarkedColor
, 1, GetStr(MSG_Label_Selected
));
341 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->normalfont
, MUICFG_TextEditor_NormalFont
, 1, GetStr(MSG_Label_Normal
));
342 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->smooth
, MUICFG_TextEditor_Smooth
, 1, GetStr(MSG_Label_Smooth
));
343 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->typenspell
, MUICFG_TextEditor_TypeNSpell
, 1, GetStr(MSG_ConfigMenu_TypeNSpell
));
344 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->CheckWord
, MUICFG_TextEditor_CheckWord
, 1, GetStr(MSG_ConfigMenu_CheckWord
));
345 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->tabsize
, MUICFG_TextEditor_TabSize
, 1, GetStr(MSG_Label_TabSize
));
346 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->undosize
, MUICFG_TextEditor_UndoSize
, 1, GetStr(MSG_Label_UndoLevel
));
347 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->textcolor
, MUICFG_TextEditor_TextColor
, 1, GetStr(MSG_Label_Text
));
348 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->separatorshine
, MUICFG_TextEditor_SeparatorShine
, 1, GetStr(MSG_Label_SeparatorShine
));
349 DoMethod(obj
, MUIM_Mccprefs_RegisterGadget
, data
->separatorshadow
, MUICFG_TextEditor_SeparatorShadow
, 1, GetStr(MSG_Label_SeparatorShadow
));
352 set(data
->frame
, MUIA_Disabled
, TRUE
);
357 CoerceMethod(cl
, obj
, OM_DISPOSE
);
362 ULONG
Dispose(REG(a0
, struct IClass
*cl
), REG(a2
, Object
*obj
), REG(a1
, Msg msg
))
364 struct InstData_MCP
*data
= INST_DATA(cl
, obj
);
365 Object
*editpopup
= data
->editpopup
;
369 DoMethod(obj
, OM_REMMEMBER
, data
->CfgObj
);
370 MUI_DisposeObject(data
->CfgObj
);
374 MUI_DisposeObject(editpopup
);
376 return(DoSuperMethodA(cl
, obj
, msg
));
379 ULONG
GadgetsToConfig(REG(a0
, struct IClass
*cl
), REG(a2
, Object
*obj
), REG(a1
, struct MUIP_Settingsgroup_GadgetsToConfig
*msg
))
381 struct InstData_MCP
*data
= INST_DATA(cl
, obj
);
384 // first save the config version
385 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_ConfigVersion
);
387 ExportKeys(msg
->configdata
, data
);
389 get(data
->frame
, MUIA_Framedisplay_Spec
, &cfg_data
);
390 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_FrameSpec
), MUICFG_TextEditor_Frame
);
392 get(data
->background
, MUIA_Imagedisplay_Spec
, &cfg_data
);
393 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_ImageSpec
), MUICFG_TextEditor_Background
);
395 get(data
->blinkspeed
, MUIA_Numeric_Value
, &cfg_data
);
396 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_BlinkSpeed
);
398 get(data
->blockqual
, MUIA_Cycle_Active
, &cfg_data
);
399 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_BlockQual
);
401 get(data
->cursorcolor
, MUIA_Pendisplay_Spec
, &cfg_data
);
402 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_PenSpec
), MUICFG_TextEditor_CursorColor
);
404 get(data
->cursorwidth
, MUIA_Numeric_Value
, &cfg_data
);
405 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_CursorWidth
);
407 get(data
->fixedfont
, MUIA_String_Contents
, &cfg_data
);
408 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, strlen((char *)cfg_data
)+1, MUICFG_TextEditor_FixedFont
);
410 get(data
->frame
, MUIA_Framedisplay_Spec
, &cfg_data
);
411 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_FrameSpec
), MUICFG_TextEditor_Frame
);
413 get(data
->highlightcolor
, MUIA_Pendisplay_Spec
, &cfg_data
);
414 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_PenSpec
), MUICFG_TextEditor_HighlightColor
);
416 get(data
->markedcolor
, MUIA_Pendisplay_Spec
, &cfg_data
);
417 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_PenSpec
), MUICFG_TextEditor_MarkedColor
);
419 get(data
->normalfont
, MUIA_String_Contents
, &cfg_data
);
420 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, strlen((char *)cfg_data
)+1, MUICFG_TextEditor_NormalFont
);
425 get(data
->LookupExeType
, MUIA_Cycle_Active
, buffer
);
426 get(data
->lookupcmd
, MUIA_String_Contents
, &cfg_data
);
427 CopyMem((APTR
)cfg_data
, &buffer
[1], 256);
428 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, buffer
, strlen((char *)cfg_data
)+5, MUICFG_TextEditor_LookupCmd
);
430 get(data
->SuggestExeType
, MUIA_Cycle_Active
, buffer
);
431 get(data
->suggestcmd
, MUIA_String_Contents
, &cfg_data
);
432 CopyMem((APTR
)cfg_data
, &buffer
[1], 256);
433 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, buffer
, strlen((char *)cfg_data
)+5, MUICFG_TextEditor_SuggestCmd
);
436 get(data
->smooth
, MUIA_Selected
, &cfg_data
);
437 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_Smooth
);
439 get(data
->typenspell
, MUIA_Selected
, &cfg_data
);
440 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_TypeNSpell
);
442 get(data
->CheckWord
, MUIA_Selected
, &cfg_data
);
443 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_CheckWord
);
445 get(data
->tabsize
, MUIA_Numeric_Value
, &cfg_data
);
446 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_TabSize
);
448 get(data
->undosize
, MUIA_Numeric_Value
, &cfg_data
);
449 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, &cfg_data
, sizeof(LONG
), MUICFG_TextEditor_UndoSize
);
451 get(data
->textcolor
, MUIA_Pendisplay_Spec
, &cfg_data
);
452 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_PenSpec
), MUICFG_TextEditor_TextColor
);
454 get(data
->separatorshine
, MUIA_Pendisplay_Spec
, &cfg_data
);
455 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_PenSpec
), MUICFG_TextEditor_SeparatorShine
);
457 get(data
->separatorshadow
, MUIA_Pendisplay_Spec
, &cfg_data
);
458 DoMethod(msg
->configdata
, MUIM_Dataspace_Add
, cfg_data
, sizeof(struct MUI_PenSpec
), MUICFG_TextEditor_SeparatorShadow
);
463 ULONG
ConfigToGadgets(REG(a0
, struct IClass
*cl
), REG(a2
, Object
*obj
), REG(a1
, struct MUIP_Settingsgroup_ConfigToGadgets
*msg
))
465 struct InstData_MCP
*data
= INST_DATA(cl
, obj
);
468 /* if(cfg_data = (APTR)DoMethod(msg->configdata, MUIM_Dataspace_Find, MUICFG_TextEditor_ConfigVersion))
469 kprintf("Config version: %ld\n", *((ULONG *)cfg_data));
470 else kprintf("Obsolete config\n");
472 ImportKeys(msg
->configdata
, data
);
474 if((cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_LookupCmd
)))
476 set(data
->LookupExeType
, MUIA_Cycle_Active
, *(ULONG
*)cfg_data
);
477 set(data
->lookupcmd
, MUIA_String_Contents
, (ULONG
*)cfg_data
+1);
481 set(data
->LookupExeType
, MUIA_Cycle_Active
, 0);
482 set(data
->lookupcmd
, MUIA_String_Contents
, "");
485 if((cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_SuggestCmd
)))
487 set(data
->SuggestExeType
, MUIA_Cycle_Active
, *(ULONG
*)cfg_data
);
488 set(data
->suggestcmd
, MUIA_String_Contents
, (ULONG
*)cfg_data
+1);
492 set(data
->SuggestExeType
, MUIA_Cycle_Active
, 1);
493 set(data
->suggestcmd
, MUIA_String_Contents
, "\"Open('f', 'T:Matches', 'W');WriteLn('f', '%s');Close('f')");
496 set(data
->frame
, MUIA_Framedisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_Frame
)) ? cfg_data
: "302200");
497 set(data
->background
, MUIA_Imagedisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_Background
)) ? cfg_data
: "2:m2");
498 set(data
->blinkspeed
, MUIA_Numeric_Value
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_BlinkSpeed
)) ? *(ULONG
*)cfg_data
: 0);
499 set(data
->blockqual
, MUIA_Cycle_Active
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_BlockQual
)) ? *(ULONG
*)cfg_data
: 0);
500 set(data
->cursorcolor
, MUIA_Pendisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_CursorColor
)) ? cfg_data
: "m0");
501 set(data
->cursorwidth
, MUIA_Numeric_Value
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_CursorWidth
)) ? *(ULONG
*)cfg_data
: 6);
502 set(data
->fixedfont
, MUIA_String_Contents
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_FixedFont
)) ? cfg_data
: "");
503 set(data
->highlightcolor
, MUIA_Pendisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_HighlightColor
)) ? cfg_data
: "m0");
504 set(data
->markedcolor
, MUIA_Pendisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_MarkedColor
)) ? cfg_data
: "m6");
505 set(data
->normalfont
, MUIA_String_Contents
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_NormalFont
)) ? cfg_data
: "");
506 set(data
->smooth
, MUIA_Selected
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_Smooth
)) ? *(ULONG
*)cfg_data
: TRUE
);
507 set(data
->typenspell
, MUIA_Selected
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_TypeNSpell
)) ? *(ULONG
*)cfg_data
: FALSE
);
508 set(data
->CheckWord
, MUIA_Selected
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_CheckWord
)) ? *(ULONG
*)cfg_data
: FALSE
);
509 set(data
->tabsize
, MUIA_Numeric_Value
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_TabSize
)) ? *(ULONG
*)cfg_data
: 4);
510 set(data
->undosize
, MUIA_Numeric_Value
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_UndoSize
)) ? *(ULONG
*)cfg_data
: 500);
511 set(data
->textcolor
, MUIA_Pendisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_TextColor
)) ? cfg_data
: "m5");
512 set(data
->separatorshine
, MUIA_Pendisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_SeparatorShine
)) ? cfg_data
: "m1");
513 set(data
->separatorshadow
, MUIA_Pendisplay_Spec
, (cfg_data
= (void *)DoMethod(msg
->configdata
, MUIM_Dataspace_Find
, MUICFG_TextEditor_SeparatorShadow
)) ? cfg_data
: "m3");