JXChooseMonoFont::JXChooseMonoFont ( JXContainer* enclosure, const HSizingOption hSizing, const VSizingOption vSizing, const JCoordinate x, const JCoordinate y, const JCoordinate w, const JCoordinate h ) : JXWidgetSet(enclosure, hSizing, vSizing, x,y, w,h) { const JBoolean ok = JXXFontMenu::Create(fontRegex, CompareFontNames, kFontMenuTitleStr, this, kFixedLeft, kFixedTop, 0,0, w,25, &itsFontMenu); assert( ok ); PrependOtherMonospaceFonts(itsFontMenu); itsFontMenu->SetFontName(JGetMonospaceFontName()); itsFontMenu->SetToPopupChoice(); ListenTo(itsFontMenu); itsSizeMenu = jnew JXFontSizeMenu(JGetMonospaceFontName(), kSizeMenuTitleStr, this, kFixedLeft, kFixedTop, 0,30, w,25); assert( itsSizeMenu != NULL ); itsSizeMenu->SetFontSize(JGetDefaultMonoFontSize()); itsSizeMenu->SetToPopupChoice(); ListenTo(itsSizeMenu); UpdateMenus(kJTrue); SetNeedsInternalFTC(); }
void JXFSBindingTable::TableDrawCell ( JPainter& p, const JPoint& cell, const JRect& rect ) { JPoint editCell; if (GetEditedCell(&editCell) && cell == editCell) { return; } HilightIfSelected(p, cell, rect); const JFSBinding* b = itsBindingList->GetBinding(cell.y); JFSBinding::CommandType type; JBoolean singleFile; const JString& cmd = b->GetCommand(&type, &singleFile); if (cell.x == kPatternColumn) { p.SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); JRect r = rect; r.left += kHMarginWidth; p.String(r, b->GetPattern(), JPainter::kHAlignLeft, JPainter::kVAlignCenter); p.SetFont(JGetDefaultFontName(), kJDefaultFontSize, JFontStyle()); } else if (cell.x == kCommandColumn) { p.SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); JRect r = rect; r.left += kHMarginWidth; p.String(r, cmd, JPainter::kHAlignLeft, JPainter::kVAlignCenter); p.SetFont(JGetDefaultFontName(), kJDefaultFontSize, JFontStyle()); } else if (cell.x == kTypeColumn) { const JString& str = itsTypeMenu->GetItemText(kCmdTypeToMenuIndex[type]); p.String(rect, str, JPainter::kHAlignCenter, JPainter::kVAlignCenter); } else if (cell.x == kSingleFileColumn && singleFile) { JRect r; r.top = rect.ycenter(); r.left = rect.xcenter(); r.bottom = r.top+1; r.right = r.left+1; r.Expand(3, 3); p.SetFilling(kJTrue); p.Ellipse(r); p.SetFilling(kJFalse); } }
JXPathInput::JXPathInput ( JXContainer* enclosure, const HSizingOption hSizing, const VSizingOption vSizing, const JCoordinate x, const JCoordinate y, const JCoordinate w, const JCoordinate h ) : JXInputField(enclosure, hSizing, vSizing, x,y, w,h), itsCompleter(NULL), itsCompletionMenu(NULL) { itsAllowInvalidPathFlag = kJFalse; itsRequireWriteFlag = kJFalse; itsExpectURLDropFlag = kJFalse; SetIsRequired(); SetCharacterInWordFunction(IsCharacterInWord); SetDefaultFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); ShouldBroadcastCaretLocationChanged(kJTrue); SetHint(JGetString(kHintID)); ListenTo(this); }
const JCharacter* JXPathInput::GetFont ( JSize* size ) { *size = kJDefaultMonoFontSize; return JGetMonospaceFontName(); }
void CMChooseProcessDialog::BuildWindow() { // begin JXLayout JXWindow* window = new JXWindow(this, 390,500, ""); assert( window != NULL ); JXScrollbarSet* scrollbarSet = new JXScrollbarSet(window, JXWidget::kHElastic, JXWidget::kVElastic, 20,50, 350,400); assert( scrollbarSet != NULL ); itsProcessIDInput = new JXIntegerInput(window, JXWidget::kHElastic, JXWidget::kFixedBottom, 90,470, 80,20); assert( itsProcessIDInput != NULL ); JXStaticText* obj1_JXLayout = new JXStaticText(JGetString("obj1_JXLayout::CMChooseProcessDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedBottom, 20,470, 70,20); assert( obj1_JXLayout != NULL ); obj1_JXLayout->SetToLabel(); JXTextButton* cancelButton = new JXTextButton(JGetString("cancelButton::CMChooseProcessDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedBottom, 215,470, 60,20); assert( cancelButton != NULL ); JXTextButton* okButton = new JXTextButton(JGetString("okButton::CMChooseProcessDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedBottom, 310,470, 60,20); assert( okButton != NULL ); okButton->SetShortcuts(JGetString("okButton::CMChooseProcessDialog::shortcuts::JXLayout")); JXStaticText* obj2_JXLayout = new JXStaticText(JGetString("obj2_JXLayout::CMChooseProcessDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,20, 360,20); assert( obj2_JXLayout != NULL ); obj2_JXLayout->SetToLabel(); // end JXLayout window->SetTitle("Choose process"); SetButtons(okButton, cancelButton); itsText = new CMProcessText(this, scrollbarSet, scrollbarSet->GetScrollEnclosure(), JXWidget::kHElastic, JXWidget::kVElastic, 0,0, 10,10); assert( itsText != NULL ); itsText->FitToEnclosure(); itsText->SetDefaultFont(JGetMonospaceFontName(), kJDefaultMonoFontSize); }
SVNListBase::SVNListBase ( SVNMainDirector* director, JXTextMenu* editMenu, const JString& cmd, const JBoolean refreshRepo, const JBoolean refreshStatus, const JBoolean reload, const JBoolean enableContextMenu, JXScrollbarSet* scrollbarSet, JXContainer* enclosure, const HSizingOption hSizing, const VSizingOption vSizing, const JCoordinate x, const JCoordinate y, const JCoordinate w, const JCoordinate h ) : JXStringList(scrollbarSet, enclosure, hSizing, vSizing, x, y, w, h), SVNTabBase(director), itsCmd(cmd), itsRefreshRepoFlag(refreshRepo), itsRefreshStatusFlag(refreshStatus), itsReloadOpenFilesFlag(reload), itsEditMenu(editMenu), itsEnableContextMenuFlag(enableContextMenu), itsContextMenu(NULL), itsProcess(NULL), itsMessageLink(NULL), itsErrorLink(NULL) { SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize); SetSelectionBehavior(kJTrue, kJTrue); itsLineList = new JPtrArray<JString>(JPtrArrayT::kDeleteAll); assert( itsLineList != NULL ); itsLineList->SetCompareObject(CompareLines(this)); SetStringList(itsLineList); itsErrorList = new JPtrArray<JString>(JPtrArrayT::kDeleteAll); assert( itsErrorList != NULL ); itsSavedSelection = new JPtrArray<JString>(JPtrArrayT::kDeleteAll); assert( itsSavedSelection != NULL ); itsSavedSelection->SetCompareFunction(JCompareStringsCaseSensitive); FitToEnclosure(); ListenTo(itsEditMenu); }
JString GPrefsMgr::GetDefaultMonoFont() { if (IDValid(kGDefaultMonoFontID)) { std::string data; JBoolean ok = GetData(kGDefaultMonoFontID, &data); assert( ok ); std::istringstream dataStream(data); JString name; dataStream >> name; return name; } SetDefaultMonoFont(JGetMonospaceFontName()); return GetDefaultMonoFont(); }
JFontID GPrefsMgr::GetDefaultMonoFontID() { if (IDValid(kGDefaultMonoFontID)) { std::string data; JBoolean ok = GetData(kGDefaultMonoFontID, &data); assert( ok ); std::istringstream dataStream(data); JString name; dataStream >> name; JFontID id; if (JXGetApplication()->GetCurrentDisplay()->GetXFontManager()->GetFontID(name, &id)) { return id; } } SetDefaultMonoFont(JGetMonospaceFontName()); return GetDefaultMonoFontID(); }
JXInputField* JXFSBindingTable::CreateXInputField ( const JPoint& cell, const JCoordinate x, const JCoordinate y, const JCoordinate w, const JCoordinate h ) { assert( itsTextInput == NULL ); JTableSelection& s = GetTableSelection(); s.ClearSelection(); s.SelectCell(cell); itsTextInput = new JXInputField(this, kFixedLeft, kFixedTop, x,y, w,h); assert( itsTextInput != NULL ); const JFSBinding* b = itsBindingList->GetBinding(cell.y); if (cell.x == kPatternColumn) { itsTextInput->SetText(b->GetPattern()); } else if (cell.x == kCommandColumn) { JFSBinding::CommandType type; JBoolean singleFile; const JString& cmd = b->GetCommand(&type, &singleFile); itsTextInput->SetText(cmd); } itsTextInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsTextInput->SetIsRequired(); ListenTo(itsTextInput); return itsTextInput; }
JXFSBindingTable::JXFSBindingTable ( JFSBindingList* list, JXTextButton* addButton, JXTextButton* removeButton, JXTextButton* duplicateButton, JXScrollbarSet* scrollbarSet, JXContainer* enclosure, const HSizingOption hSizing, const VSizingOption vSizing, const JCoordinate x, const JCoordinate y, const JCoordinate w, const JCoordinate h ) : JXEditTable(1,1, scrollbarSet, enclosure, hSizing, vSizing, x, y, w, h), itsBindingList(list), itsAddButton(addButton), itsRemoveButton(removeButton), itsDuplicateButton(duplicateButton), itsTextInput(NULL) { // row height const JSize rowHeight = 2*kVMarginWidth + JMax( (GetFontManager())->GetLineHeight(JGetDefaultFontName(), kJDefaultFontSize, JFontStyle()), (GetFontManager())->GetLineHeight(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle())); SetDefaultRowHeight(rowHeight); // buttons ListenTo(itsAddButton); ListenTo(itsRemoveButton); ListenTo(itsDuplicateButton); // type menu itsTypeMenu = new JXTextMenu("", this, kFixedLeft, kFixedTop, 0,0, 10,10); assert( itsTypeMenu != NULL ); itsTypeMenu->Hide(); itsTypeMenu->SetToHiddenPopupMenu(kJTrue); itsTypeMenu->SetMenuItems(kTypeMenuStr); itsTypeMenu->SetUpdateAction(JXMenu::kDisableNone); ListenTo(itsTypeMenu); // regex for testing itsTestRegex = new JRegex; assert( itsTestRegex != NULL ); // data for (JIndex i=1; i<=kColCount; i++) { AppendCols(1, kInitColWidth[i-1]); } UpdateColWidths(); const JSize rowCount = itsBindingList->GetElementCount(); AppendRows(rowCount); UpdateButtons(); ListenTo(&(GetTableSelection())); }
void GPrefsMgr::UpgradeData ( const JBoolean isNew, const JFileVersion currentVersion ) { if (isNew) { JString homeDir; JBoolean fileok = JGetHomeDirectory(&homeDir); JAppendDirSeparator(&homeDir); JString outbox = homeDir + ".outbox"; SetCurrentOutbox(outbox); JString username = JGetUserName(); JString inbox = "/var/spool/mail/" + username; SetDefaultInbox(inbox); ShowStateInTitle(kJTrue); SetPopServer(JString("pop-server")); UsePopServer(kJFalse); SetLeaveOnServer(kJFalse); SetPopUserName(JString("name")); SetPopPasswd(JString("")); SetRememberPasswd(kJFalse); UseAPop(kJFalse); AutoInsertQuote(kJTrue); AutoCheckMail(kJFalse); SetCheckMailDelay(30); SetDefaultMonoFont(JGetMonospaceFontName()); JCharacter* var = getenv("REPLYTO"); if (var != NULL) { JString varStr(var); SetReplyTo(varStr); } ShowSenderString(kJTrue); SetSenderString("On $d, $f wrote:"); JXGetWebBrowser()->SetComposeMailCmd(kGMDefaultMailtoString); SetFilterFile(".procmailrc"); } else { if (currentVersion < 2) { ShowStateInTitle(kJTrue); } if (currentVersion < 3) { UseAPop(kJFalse); AutoInsertQuote(kJTrue); AutoCheckMail(kJFalse); SetCheckMailDelay(30); } if (currentVersion < 4) { JCharacter* var = getenv("REPLYTO"); if (var != NULL) { JString varStr(var); SetReplyTo(varStr); } ShowSenderString(kJTrue); SetSenderString("On $d, $f wrote:"); } if (currentVersion < 5) { RemoveData(kGHelpSetupID); JXGetWebBrowser()->SetComposeMailCmd(kGMDefaultMailtoString); } if (currentVersion < 7) { SetFilterFile(".procmailrc"); } if (currentVersion < 10) { RemoveData(42); RemoveData(45); } } }
void CBRunCommandDialog::BuildWindow() { // begin JXLayout JXWindow* window = new JXWindow(this, 470,260, ""); assert( window != NULL ); JXTextButton* cancelButton = new JXTextButton(JGetString("cancelButton::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 210,235, 60,20); assert( cancelButton != NULL ); itsRunButton = new JXTextButton(JGetString("itsRunButton::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 389,234, 62,22); assert( itsRunButton != NULL ); itsRunButton->SetShortcuts(JGetString("itsRunButton::CBRunCommandDialog::shortcuts::JXLayout")); itsHelpButton = new JXTextButton(JGetString("itsHelpButton::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 300,235, 60,20); assert( itsHelpButton != NULL ); itsHelpButton->SetShortcuts(JGetString("itsHelpButton::CBRunCommandDialog::shortcuts::JXLayout")); itsPathInput = new CBCommandPathInput(window, JXWidget::kHElastic, JXWidget::kFixedTop, 20,40, 320,20); assert( itsPathInput != NULL ); itsSaveAllCB = new JXTextCheckbox(JGetString("itsSaveAllCB::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,180, 220,20); assert( itsSaveAllCB != NULL ); itsSaveAllCB->SetShortcuts(JGetString("itsSaveAllCB::CBRunCommandDialog::shortcuts::JXLayout")); itsOneAtATimeCB = new JXTextCheckbox(JGetString("itsOneAtATimeCB::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,200, 220,20); assert( itsOneAtATimeCB != NULL ); itsOneAtATimeCB->SetShortcuts(JGetString("itsOneAtATimeCB::CBRunCommandDialog::shortcuts::JXLayout")); itsUseWindowCB = new JXTextCheckbox(JGetString("itsUseWindowCB::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 240,130, 220,20); assert( itsUseWindowCB != NULL ); itsUseWindowCB->SetShortcuts(JGetString("itsUseWindowCB::CBRunCommandDialog::shortcuts::JXLayout")); itsIsMakeCB = new JXTextCheckbox(JGetString("itsIsMakeCB::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,130, 220,20); assert( itsIsMakeCB != NULL ); itsIsMakeCB->SetShortcuts(JGetString("itsIsMakeCB::CBRunCommandDialog::shortcuts::JXLayout")); itsCmdInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 20,90, 370,20); assert( itsCmdInput != NULL ); JXStaticText* obj1_JXLayout = new JXStaticText(JGetString("obj1_JXLayout::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,70, 130,20); assert( obj1_JXLayout != NULL ); obj1_JXLayout->SetToLabel(); JXStaticText* obj2_JXLayout = new JXStaticText(JGetString("obj2_JXLayout::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,20, 200,20); assert( obj2_JXLayout != NULL ); obj2_JXLayout->SetToLabel(); itsPathHistoryMenu = new JXPathHistoryMenu(kHistoryLength, "", window, JXWidget::kFixedRight, JXWidget::kFixedTop, 340,40, 30,20); assert( itsPathHistoryMenu != NULL ); itsChoosePathButton = new JXTextButton(JGetString("itsChoosePathButton::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 390,40, 60,20); assert( itsChoosePathButton != NULL ); itsChooseCmdButton = new JXTextButton(JGetString("itsChooseCmdButton::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 390,90, 60,20); assert( itsChooseCmdButton != NULL ); itsRaiseCB = new JXTextCheckbox(JGetString("itsRaiseCB::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 240,150, 220,20); assert( itsRaiseCB != NULL ); itsRaiseCB->SetShortcuts(JGetString("itsRaiseCB::CBRunCommandDialog::shortcuts::JXLayout")); itsBeepCB = new JXTextCheckbox(JGetString("itsBeepCB::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 240,170, 220,20); assert( itsBeepCB != NULL ); itsBeepCB->SetShortcuts(JGetString("itsBeepCB::CBRunCommandDialog::shortcuts::JXLayout")); itsSaveCmdMenu = new JXTextMenu(JGetString("itsSaveCmdMenu::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,235, 90,20); assert( itsSaveCmdMenu != NULL ); itsIsCVSCB = new JXTextCheckbox(JGetString("itsIsCVSCB::CBRunCommandDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,150, 220,20); assert( itsIsCVSCB != NULL ); itsIsCVSCB->SetShortcuts(JGetString("itsIsCVSCB::CBRunCommandDialog::shortcuts::JXLayout")); // end JXLayout window->SetTitle(JGetString(kWindowTitleID)); SetButtons(itsRunButton, cancelButton); UseModalPlacement(kJFalse); window->PlaceAsDialogWindow(); window->LockCurrentMinSize(); ListenTo(itsHelpButton); ListenTo(itsChoosePathButton); ListenTo(itsChooseCmdButton); ListenTo(itsPathHistoryMenu); ListenTo(itsIsMakeCB); ListenTo(itsIsCVSCB); ListenTo(itsUseWindowCB); itsPathInput->SetText("." ACE_DIRECTORY_SEPARATOR_STR); itsPathInput->ShouldAllowInvalidPath(); itsPathInput->ShouldBroadcastAllTextChanged(kJTrue); ListenTo(itsPathInput); if (itsProjDoc != NULL) { itsPathInput->SetBasePath(itsProjDoc->GetFilePath()); } itsCmdInput->ShouldBroadcastAllTextChanged(kJTrue); itsCmdInput->SetCharacterInWordFunction(JXChooseSaveFile::IsCharacterInWord); ListenTo(itsCmdInput); itsCmdInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsSaveCmdMenu->SetMenuItems(kSaveCmdMenuStr, "CBRunCommandDialog"); ListenTo(itsSaveCmdMenu); // create hidden JXDocument so Meta-# shortcuts work JXDocumentMenu* fileListMenu = new JXDocumentMenu("", window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 0,-20, 10,10); assert( fileListMenu != NULL ); UpdateDisplay(); }
void SyGFindFileDialog::BuildWindow() { // begin JXLayout JXWindow* window = new JXWindow(this, 360,220, ""); assert( window != NULL ); itsActionRG = new JXRadioGroup(window, JXWidget::kHElastic, JXWidget::kFixedTop, 10,50, 340,120); assert( itsActionRG != NULL ); itsCloseButton = new JXTextButton(JGetString("itsCloseButton::SyGFindFileDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 120,190, 60,20); assert( itsCloseButton != NULL ); itsCloseButton->SetShortcuts(JGetString("itsCloseButton::SyGFindFileDialog::shortcuts::JXLayout")); itsSearchButton = new JXTextButton(JGetString("itsSearchButton::SyGFindFileDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 280,190, 60,20); assert( itsSearchButton != NULL ); itsSearchButton->SetShortcuts(JGetString("itsSearchButton::SyGFindFileDialog::shortcuts::JXLayout")); itsFileInput = new JXInputField(itsActionRG, JXWidget::kHElastic, JXWidget::kFixedTop, 35,30, 295,20); assert( itsFileInput != NULL ); JXTextRadioButton* obj1_JXLayout = new JXTextRadioButton(kFindFileAction, JGetString("obj1_JXLayout::SyGFindFileDialog::JXLayout"), itsActionRG, JXWidget::kHElastic, JXWidget::kFixedTop, 10,10, 320,20); assert( obj1_JXLayout != NULL ); obj1_JXLayout->SetShortcuts(JGetString("obj1_JXLayout::SyGFindFileDialog::shortcuts::JXLayout")); itsHelpButton = new JXTextButton(JGetString("itsHelpButton::SyGFindFileDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 200,190, 60,20); assert( itsHelpButton != NULL ); itsHelpButton->SetShortcuts(JGetString("itsHelpButton::SyGFindFileDialog::shortcuts::JXLayout")); itsStayOpenCB = new JXTextCheckbox(JGetString("itsStayOpenCB::SyGFindFileDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,190, 90,20); assert( itsStayOpenCB != NULL ); itsExprInput = new JXInputField(itsActionRG, JXWidget::kHElastic, JXWidget::kFixedTop, 35,90, 295,20); assert( itsExprInput != NULL ); JXTextRadioButton* obj2_JXLayout = new JXTextRadioButton(kFindExprAction, JGetString("obj2_JXLayout::SyGFindFileDialog::JXLayout"), itsActionRG, JXWidget::kHElastic, JXWidget::kFixedTop, 10,70, 320,20); assert( obj2_JXLayout != NULL ); obj2_JXLayout->SetShortcuts(JGetString("obj2_JXLayout::SyGFindFileDialog::shortcuts::JXLayout")); JXStaticText* obj3_JXLayout = new JXStaticText(JGetString("obj3_JXLayout::SyGFindFileDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,20, 50,20); assert( obj3_JXLayout != NULL ); obj3_JXLayout->SetToLabel(); itsPathInput = new JXPathInput(window, JXWidget::kHElastic, JXWidget::kFixedTop, 70,20, 210,20); assert( itsPathInput != NULL ); itsChoosePathButton = new JXTextButton(JGetString("itsChoosePathButton::SyGFindFileDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 280,20, 60,20); assert( itsChoosePathButton != NULL ); // end JXLayout window->SetTitle("Find files"); window->SetCloseAction(JXWindow::kDeactivateDirector); window->PlaceAsDialogWindow(); window->LockCurrentMinSize(); window->ShouldFocusWhenShow(kJTrue); itsActionRG->SetBorderWidth(0); ListenTo(itsChoosePathButton); ListenTo(itsActionRG); ListenTo(itsSearchButton); ListenTo(itsCloseButton); ListenTo(itsHelpButton); itsPathInput->ShouldAllowInvalidPath(); itsFileInput->ShouldBroadcastAllTextChanged(kJTrue); itsFileInput->SetCharacterInWordFunction(JXChooseSaveFile::IsCharacterInWord); itsFileInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); ListenTo(itsFileInput); itsExprInput->ShouldBroadcastAllTextChanged(kJTrue); itsExprInput->SetCharacterInWordFunction(JXChooseSaveFile::IsCharacterInWord); itsExprInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); ListenTo(itsExprInput); itsStayOpenCB->SetState(kJTrue); UpdateDisplay(); }
void JXEditWWWPrefsDialog::BuildWindow ( const JCharacter* showURLCmd, const JCharacter* showFileContentCmd, const JCharacter* showFileLocationCmd, const JCharacter* composeMailCmd ) { // begin JXLayout JXWindow* window = new JXWindow(this, 520,290, ""); assert( window != NULL ); itsShowURLCmdInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 250,20, 250,20); assert( itsShowURLCmdInput != NULL ); itsShowFileContentCmdInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 250,80, 250,20); assert( itsShowFileContentCmdInput != NULL ); itsShowFileLocationCmdInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 250,140, 250,20); assert( itsShowFileLocationCmdInput != NULL ); itsComposeMailCmdInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 250,200, 250,20); assert( itsComposeMailCmdInput != NULL ); JXTextButton* cancelButton = new JXTextButton(JGetString("cancelButton::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 120,260, 70,20); assert( cancelButton != NULL ); JXTextButton* okButton = new JXTextButton(JGetString("okButton::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 330,260, 70,20); assert( okButton != NULL ); okButton->SetShortcuts(JGetString("okButton::JXEditWWWPrefsDialog::shortcuts::JXLayout")); JXStaticText* obj1_JXLayout = new JXStaticText(JGetString("obj1_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 250,40, 252,20); assert( obj1_JXLayout != NULL ); obj1_JXLayout->SetToLabel(); JXStaticText* obj2_JXLayout = new JXStaticText(JGetString("obj2_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,20, 230,20); assert( obj2_JXLayout != NULL ); obj2_JXLayout->SetToLabel(); JXStaticText* obj3_JXLayout = new JXStaticText(JGetString("obj3_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,200, 230,20); assert( obj3_JXLayout != NULL ); obj3_JXLayout->SetToLabel(); JXStaticText* obj4_JXLayout = new JXStaticText(JGetString("obj4_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 250,220, 250,20); assert( obj4_JXLayout != NULL ); obj4_JXLayout->SetToLabel(); JXStaticText* obj5_JXLayout = new JXStaticText(JGetString("obj5_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 250,100, 251,20); assert( obj5_JXLayout != NULL ); obj5_JXLayout->SetToLabel(); JXStaticText* obj6_JXLayout = new JXStaticText(JGetString("obj6_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,80, 230,20); assert( obj6_JXLayout != NULL ); obj6_JXLayout->SetToLabel(); JXStaticText* obj7_JXLayout = new JXStaticText(JGetString("obj7_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 250,160, 260,20); assert( obj7_JXLayout != NULL ); obj7_JXLayout->SetToLabel(); JXStaticText* obj8_JXLayout = new JXStaticText(JGetString("obj8_JXLayout::JXEditWWWPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,140, 230,20); assert( obj8_JXLayout != NULL ); obj8_JXLayout->SetToLabel(); // end JXLayout window->SetTitle("Web Browser Preferences"); SetButtons(okButton, cancelButton); itsShowURLCmdInput->SetText(showURLCmd); itsShowURLCmdInput->SetIsRequired(); itsShowURLCmdInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsShowFileContentCmdInput->SetText(showFileContentCmd); itsShowFileContentCmdInput->SetIsRequired(); itsShowFileContentCmdInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsShowFileLocationCmdInput->SetText(showFileLocationCmd); itsShowFileLocationCmdInput->SetIsRequired(); itsShowFileLocationCmdInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsComposeMailCmdInput->SetText(composeMailCmd); itsComposeMailCmdInput->SetIsRequired(); itsComposeMailCmdInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); }
void JXSearchTextDialog::SetObjects ( JXInputField* searchInput, JXStringHistoryMenu* prevSearchMenu, JXTextCheckbox* ignoreCaseCB, JXTextCheckbox* entireWordCB, JXTextCheckbox* wrapSearchCB, JXTextCheckbox* searchIsRegexCB, JXTextCheckbox* singleLineCB, JXInputField* replaceInput, JXStringHistoryMenu* prevReplaceMenu, JXTextCheckbox* replaceIsRegexCB, JXTextCheckbox* preserveCaseCB, JXTextCheckbox* stayOpenCB, JXTextCheckbox* retainFocusCB, JXSearchTextButton* findFwdButton, JXSearchTextButton* findBackButton, JXTextButton* replaceButton, JXSearchTextButton* replaceFindFwdButton, JXSearchTextButton* replaceFindBackButton, JXSearchTextButton* replaceAllFwdButton, JXSearchTextButton* replaceAllBackButton, JXTextButton* replaceAllInSelButton, JXTextButton* closeButton, JXTextButton* helpButton, JXTextButton* qRefButton ) { JXWindow* window = searchInput->GetWindow(); window->SetTitle("Search text"); window->SetCloseAction(JXWindow::kDeactivateDirector); window->PlaceAsDialogWindow(); window->LockCurrentMinSize(); window->ShouldFocusWhenShow(kJTrue); ListenTo(window); itsSearchInput = searchInput; itsPrevSearchMenu = prevSearchMenu; itsIgnoreCaseCB = ignoreCaseCB; itsEntireWordCB = entireWordCB; itsWrapSearchCB = wrapSearchCB; itsSearchIsRegexCB = searchIsRegexCB; itsSingleLineCB = singleLineCB; itsReplaceInput = replaceInput; itsPrevReplaceMenu = prevReplaceMenu; itsReplaceIsRegexCB = replaceIsRegexCB; itsPreserveCaseCB = preserveCaseCB; itsStayOpenCB = stayOpenCB; itsRetainFocusCB = retainFocusCB; itsFindFwdButton = findFwdButton; itsFindBackButton = findBackButton; itsReplaceButton = replaceButton; itsReplaceFindFwdButton = replaceFindFwdButton; itsReplaceFindBackButton = replaceFindBackButton; itsReplaceAllFwdButton = replaceAllFwdButton; itsReplaceAllBackButton = replaceAllBackButton; itsReplaceAllInSelButton = replaceAllInSelButton; itsCloseButton = closeButton; itsHelpButton = helpButton; itsQRefButton = qRefButton; SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize); // decor const JRect wFrame = window->GetFrame(); const JRect soFrame = itsStayOpenCB->GetFrame(); JXDownRect* line = new JXDownRect(window, JXWidget::kFixedLeft, JXWidget::kFixedTop, soFrame.left, soFrame.top-6, wFrame.right-10-soFrame.left, 2); assert( line != NULL ); line->SetBorderWidth(1); // shortcuts itsCloseButton->SetShortcuts("#W^["); itsIgnoreCaseCB->SetShortcuts("#I"); itsWrapSearchCB->SetShortcuts("#S"); itsEntireWordCB->SetShortcuts("#E"); itsSearchIsRegexCB->SetShortcuts("#X"); itsSingleLineCB->SetShortcuts("#T"); itsPreserveCaseCB->SetShortcuts("#P"); if (JXMenu::GetDefaultStyle() == JXMenu::kMacintoshStyle) { itsFindFwdButton->SetShortcuts("#G"); itsFindFwdButton->SetHint("Return / Meta-G"); itsFindBackButton->SetHint("Shift-Return / Meta-Shift-G"); itsReplaceButton->SetShortcuts("#R#="); itsReplaceButton->SetHint("Meta-R / Meta-="); itsReplaceFindFwdButton->SetShortcuts("#L"); itsReplaceFindFwdButton->SetHint("Meta-L"); itsReplaceFindBackButton->SetHint("Meta-Shift-L"); } else { itsFindFwdButton->SetShortcuts("^G"); itsFindFwdButton->SetHint("Return / Ctrl-G"); itsFindBackButton->SetHint("Shift-Return / Ctrl-Shift-G"); itsReplaceButton->SetShortcuts("#R^="); itsReplaceButton->SetHint("Meta-R / Ctrl-="); itsReplaceFindFwdButton->SetShortcuts("^L"); itsReplaceFindFwdButton->SetHint("Ctrl-L"); itsReplaceFindBackButton->SetHint("Ctrl-Shift-L"); } JXKeyModifiers modifiers(GetDisplay()); window->InstallShortcut(itsFindFwdButton, JXCtrl('M'), modifiers); modifiers.SetState(kJXShiftKeyIndex, kJTrue); window->InstallShortcut(itsFindBackButton, JXCtrl('M'), modifiers); modifiers.SetState(kJXMetaKeyIndex, kJTrue); itsReplaceIsRegexCB->SetShortcuts("#X"); // trick to underline x window->ClearShortcuts(itsReplaceIsRegexCB); window->InstallShortcut(itsReplaceIsRegexCB, 'x', modifiers); window->InstallShortcut(itsReplaceIsRegexCB, 'X', modifiers); if (JXMenu::GetDefaultStyle() != JXMenu::kMacintoshStyle) { modifiers.SetState(kJXMetaKeyIndex, kJFalse); modifiers.SetState(kJXControlKeyIndex, kJTrue); } window->InstallShortcut(itsFindBackButton, 'g', modifiers); window->InstallShortcut(itsFindBackButton, 'G', modifiers); window->InstallShortcut(itsReplaceFindBackButton, 'l', modifiers); window->InstallShortcut(itsReplaceFindBackButton, 'L', modifiers); // broadcasters ListenTo(itsFindFwdButton); ListenTo(itsFindBackButton); ListenTo(itsReplaceButton); ListenTo(itsReplaceFindFwdButton); ListenTo(itsReplaceFindBackButton); ListenTo(itsReplaceAllFwdButton); ListenTo(itsReplaceAllBackButton); ListenTo(itsReplaceAllInSelButton); ListenTo(itsHelpButton); ListenTo(itsQRefButton); ListenTo(itsCloseButton); ListenTo(itsPrevSearchMenu); ListenTo(itsPrevReplaceMenu); itsIgnoreCaseCB->SetState(kJTrue); itsWrapSearchCB->SetState(kJTrue); itsStayOpenCB->SetState(kJTrue); itsRetainFocusCB->SetState(kJTrue); // listen after setting value ListenTo(itsStayOpenCB); // XSearch data itsSearchInput->ShouldBroadcastAllTextChanged(kJTrue); ListenTo(itsSearchInput); ListenTo(itsSearchIsRegexCB); ListenTo(itsSingleLineCB); itsReplaceInput->ShouldBroadcastAllTextChanged(kJTrue); ListenTo(itsReplaceInput); ListenTo(itsReplaceIsRegexCB); ListenTo(itsPreserveCaseCB); ListenTo(itsWrapSearchCB); ListenTo(itsEntireWordCB); ListenTo(itsIgnoreCaseCB); }
void SyGEditPrefsDialog::BuildWindow ( const JCharacter* terminalCmd, const JCharacter* manViewCmd, const JCharacter* gitStatusCmd, const JCharacter* gitHistoryCmd, const JCharacter* postCheckoutCmd, const JBoolean del, const JBoolean newWindows, const JBoolean perFolderPrefs ) { // begin JXLayout JXWindow* window = new JXWindow(this, 470,380, ""); assert( window != NULL ); itsManInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 155,190, 300,20); assert( itsManInput != NULL ); itsTerminalInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 155,210, 300,20); assert( itsTerminalInput != NULL ); itsGitStatusInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 215,260, 240,20); assert( itsGitStatusInput != NULL ); JXStaticText* obj1_JXLayout = new JXStaticText(JGetString("obj1_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 10,210, 145,20); assert( obj1_JXLayout != NULL ); obj1_JXLayout->SetToLabel(); JXStaticText* obj2_JXLayout = new JXStaticText(JGetString("obj2_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 10,190, 145,20); assert( obj2_JXLayout != NULL ); obj2_JXLayout->SetToLabel(); JXTextButton* cancelButton = new JXTextButton(JGetString("cancelButton::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 105,350, 60,20); assert( cancelButton != NULL ); cancelButton->SetShortcuts(JGetString("cancelButton::SyGEditPrefsDialog::shortcuts::JXLayout")); JXTextButton* okButton = new JXTextButton(JGetString("okButton::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 305,350, 60,20); assert( okButton != NULL ); okButton->SetShortcuts(JGetString("okButton::SyGEditPrefsDialog::shortcuts::JXLayout")); JXStaticText* obj3_JXLayout = new JXStaticText(JGetString("obj3_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 155,230, 300,20); assert( obj3_JXLayout != NULL ); obj3_JXLayout->SetFontSize(8); obj3_JXLayout->SetToLabel(); itsDelCB = new JXTextCheckbox(JGetString("itsDelCB::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,70, 210,20); assert( itsDelCB != NULL ); itsAllowSpaceCB = new JXTextCheckbox(JGetString("itsAllowSpaceCB::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,120, 210,20); assert( itsAllowSpaceCB != NULL ); JXStaticText* obj4_JXLayout = new JXStaticText(JGetString("obj4_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 40,90, 310,20); assert( obj4_JXLayout != NULL ); obj4_JXLayout->SetFontSize(8); obj4_JXLayout->SetToLabel(); JXStaticText* obj5_JXLayout = new JXStaticText(JGetString("obj5_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 10,300, 205,20); assert( obj5_JXLayout != NULL ); obj5_JXLayout->SetToLabel(); JXStaticText* obj6_JXLayout = new JXStaticText(JGetString("obj6_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 215,320, 240,20); assert( obj6_JXLayout != NULL ); obj6_JXLayout->SetFontSize(8); obj6_JXLayout->SetToLabel(); JXStaticText* obj7_JXLayout = new JXStaticText(JGetString("obj7_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 10,260, 205,20); assert( obj7_JXLayout != NULL ); obj7_JXLayout->SetToLabel(); itsGitHistoryInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 215,280, 240,20); assert( itsGitHistoryInput != NULL ); JXStaticText* obj8_JXLayout = new JXStaticText(JGetString("obj8_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 10,280, 205,20); assert( obj8_JXLayout != NULL ); obj8_JXLayout->SetToLabel(); itsPostCheckoutInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 215,300, 240,20); assert( itsPostCheckoutInput != NULL ); itsOpenNewWindowsCB = new JXTextCheckbox(JGetString("itsOpenNewWindowsCB::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,20, 210,20); assert( itsOpenNewWindowsCB != NULL ); JXStaticText* obj9_JXLayout = new JXStaticText(JGetString("obj9_JXLayout::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 40,40, 410,20); assert( obj9_JXLayout != NULL ); obj9_JXLayout->SetFontSize(8); obj9_JXLayout->SetToLabel(); itsFolderPrefsCB = new JXTextCheckbox(JGetString("itsFolderPrefsCB::SyGEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,150, 220,20); assert( itsFolderPrefsCB != NULL ); // end JXLayout window->SetTitle("Edit preferences"); SetButtons(okButton, cancelButton); itsManInput->SetText(manViewCmd); itsManInput->SetIsRequired(); itsManInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsTerminalInput->SetText(terminalCmd); itsTerminalInput->SetIsRequired(); itsTerminalInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsGitStatusInput->SetText(gitStatusCmd); itsGitStatusInput->SetIsRequired(); itsGitStatusInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsGitHistoryInput->SetText(gitHistoryCmd); itsGitHistoryInput->SetIsRequired(); itsGitHistoryInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsPostCheckoutInput->SetText(postCheckoutCmd); itsPostCheckoutInput->SetIsRequired(); itsPostCheckoutInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsOpenNewWindowsCB->SetState(newWindows); itsDelCB->SetState(del); itsAllowSpaceCB->SetState(JXSaveFileInput::WillAllowSpace()); itsFolderPrefsCB->SetState(perFolderPrefs); }
void CMEditPrefsDialog::BuildWindow ( const JCharacter* gdbCmd, const JCharacter* jdbCmd, const JCharacter* editFileCmd, const JCharacter* editFileLineCmd, const JPtrArray<JString>& cSourceSuffixes, const JPtrArray<JString>& cHeaderSuffixes, const JPtrArray<JString>& javaSuffixes, const JPtrArray<JString>& phpSuffixes, const JPtrArray<JString>& fortranSuffixes ) { // begin JXLayout JXWindow* window = new JXWindow(this, 450,420, ""); assert( window != NULL ); itsGDBCmd = new CMDebuggerProgramInput(window, JXWidget::kHElastic, JXWidget::kFixedTop, 20,40, 350,20); assert( itsGDBCmd != NULL ); itsJDBCmd = new CMDebuggerProgramInput(window, JXWidget::kHElastic, JXWidget::kFixedTop, 20,110, 350,20); assert( itsJDBCmd != NULL ); itsEditFileCmdInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 190,160, 240,20); assert( itsEditFileCmdInput != NULL ); itsEditFileLineCmdInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 190,180, 240,20); assert( itsEditFileLineCmdInput != NULL ); itsCSourceSuffixInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 190,240, 240,20); assert( itsCSourceSuffixInput != NULL ); itsCHeaderSuffixInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 190,260, 240,20); assert( itsCHeaderSuffixInput != NULL ); itsJavaSuffixInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 190,290, 240,20); assert( itsJavaSuffixInput != NULL ); JXTextButton* okButton = new JXTextButton(JGetString("okButton::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedRight, JXWidget::kFixedTop, 280,390, 60,20); assert( okButton != NULL ); okButton->SetShortcuts(JGetString("okButton::CMEditPrefsDialog::shortcuts::JXLayout")); JXTextButton* cancelButton = new JXTextButton(JGetString("cancelButton::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 100,390, 60,20); assert( cancelButton != NULL ); JXStaticText* obj1_JXLayout = new JXStaticText(JGetString("obj1_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,240, 170,20); assert( obj1_JXLayout != NULL ); obj1_JXLayout->SetToLabel(); JXStaticText* obj2_JXLayout = new JXStaticText(JGetString("obj2_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,260, 170,20); assert( obj2_JXLayout != NULL ); obj2_JXLayout->SetToLabel(); JXStaticText* obj3_JXLayout = new JXStaticText(JGetString("obj3_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 160,200, 270,20); assert( obj3_JXLayout != NULL ); obj3_JXLayout->SetFontSize(8); obj3_JXLayout->SetToLabel(); JXStaticText* obj4_JXLayout = new JXStaticText(JGetString("obj4_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,160, 170,20); assert( obj4_JXLayout != NULL ); obj4_JXLayout->SetToLabel(); JXStaticText* obj5_JXLayout = new JXStaticText(JGetString("obj5_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,180, 170,20); assert( obj5_JXLayout != NULL ); obj5_JXLayout->SetToLabel(); JXStaticText* obj6_JXLayout = new JXStaticText(JGetString("obj6_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 31,290, 159,20); assert( obj6_JXLayout != NULL ); obj6_JXLayout->SetToLabel(); JXStaticText* obj7_JXLayout = new JXStaticText(JGetString("obj7_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,350, 170,20); assert( obj7_JXLayout != NULL ); obj7_JXLayout->SetToLabel(); JXStaticText* obj8_JXLayout = new JXStaticText(JGetString("obj8_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,20, 340,20); assert( obj8_JXLayout != NULL ); obj8_JXLayout->SetToLabel(); itsChooseGDBButton = new JXTextButton(JGetString("itsChooseGDBButton::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 370,40, 60,20); assert( itsChooseGDBButton != NULL ); JXStaticText* obj9_JXLayout = new JXStaticText(JGetString("obj9_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,60, 410,20); assert( obj9_JXLayout != NULL ); obj9_JXLayout->SetFontSize(8); obj9_JXLayout->SetToLabel(); JXStaticText* obj10_JXLayout = new JXStaticText(JGetString("obj10_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,90, 340,20); assert( obj10_JXLayout != NULL ); obj10_JXLayout->SetToLabel(); itsChooseJDBButton = new JXTextButton(JGetString("itsChooseJDBButton::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 370,110, 60,20); assert( itsChooseJDBButton != NULL ); JXStaticText* obj11_JXLayout = new JXStaticText(JGetString("obj11_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 20,130, 410,20); assert( obj11_JXLayout != NULL ); obj11_JXLayout->SetFontSize(8); obj11_JXLayout->SetToLabel(); itsPHPSuffixInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 190,320, 240,20); assert( itsPHPSuffixInput != NULL ); JXStaticText* obj12_JXLayout = new JXStaticText(JGetString("obj12_JXLayout::CMEditPrefsDialog::JXLayout"), window, JXWidget::kFixedLeft, JXWidget::kFixedTop, 31,320, 159,20); assert( obj12_JXLayout != NULL ); obj12_JXLayout->SetToLabel(); itsFortranSuffixInput = new JXInputField(window, JXWidget::kHElastic, JXWidget::kFixedTop, 190,350, 240,20); assert( itsFortranSuffixInput != NULL ); // end JXLayout window->SetTitle("Edit preferences"); SetButtons(okButton, cancelButton); itsGDBCmd->SetText(gdbCmd); itsGDBCmd->SetIsRequired(); itsGDBCmd->ShouldRequireExecutable(); itsJDBCmd->SetText(jdbCmd); itsJDBCmd->SetIsRequired(); itsJDBCmd->ShouldRequireExecutable(); itsEditFileCmdInput->SetText(editFileCmd); itsEditFileCmdInput->SetIsRequired(); itsEditFileCmdInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); itsEditFileLineCmdInput->SetText(editFileLineCmd); itsEditFileLineCmdInput->SetIsRequired(); itsEditFileLineCmdInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); CBMSetStringList(itsCSourceSuffixInput, cSourceSuffixes); itsCSourceSuffixInput->SetIsRequired(); itsCSourceSuffixInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); CBMSetStringList(itsCHeaderSuffixInput, cHeaderSuffixes); itsCHeaderSuffixInput->SetIsRequired(); itsCHeaderSuffixInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); CBMSetStringList(itsJavaSuffixInput, javaSuffixes); itsJavaSuffixInput->SetIsRequired(); itsJavaSuffixInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); CBMSetStringList(itsPHPSuffixInput, phpSuffixes); itsPHPSuffixInput->SetIsRequired(); itsPHPSuffixInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); CBMSetStringList(itsFortranSuffixInput, fortranSuffixes); itsFortranSuffixInput->SetIsRequired(); itsFortranSuffixInput->SetFont(JGetMonospaceFontName(), kJDefaultMonoFontSize, JFontStyle()); ListenTo(itsChooseGDBButton); ListenTo(itsChooseJDBButton); }