- QFont f1("Helvetica",10,QFont::Bold);
-
-
- strcpy(HomeDir,hdir);
- strcpy(find_text,"");
- sensitive=FALSE;
- m = new QMenuBar( this, "menu" );
- m->setFont(f1);
- QPopupMenu * file = new QPopupMenu();
- QPopupMenu * comp = new QPopupMenu();
- QPopupMenu * loglan = new QPopupMenu();
- QPopupMenu *medit = new QPopupMenu();
-
- file->setFont(f1);
- comp->setFont(f1);
- loglan->setFont(f1);
- medit->setFont(f1);
- CHECK_PTR( file );
- CHECK_PTR( comp );
- m->insertItem( "&File ", file );
- m->insertItem( "&Edit", medit );
- m->insertItem( "&Compile", this,SLOT(cmp()) );
-
-// m->insertItem( "&LOGLAN ", loglan );
- m->insertItem( "&Properties", this, SLOT(props()));
-
-
-
-
- file->insertItem( "New ", this, SLOT(create()), CTRL+Key_N);
- file->insertItem( "Open ", this, SLOT(load()), CTRL+Key_O);
- file->insertItem( "Save ", this, SLOT(save()),CTRL+Key_S);
- file->insertItem( "Save as", this, SLOT(save_as()),CTRL+Key_A);
- file->insertSeparator();
- file->insertItem( "Quit ", qApp, SLOT(quit()));
-
-// comp->insertItem( "Compile ", this, SLOT(cmp()), CTRL+Key_C);
-// comp->insertItem( "Gen ", this, SLOT(gen()), CTRL+Key_G);
-// comp->insertItem( "Compile & Gen ", this, SLOT(comp_all()));
-
-// loglan->insertItem( "Program structure", this, SLOT(log_prog()));
-// loglan->insertItem( "Unit structure", this, SLOT(log_unit()));
-
-
-
- e = new My_Edit( this, "editor" );
- connect(e,SIGNAL(cursorMove()),this,SLOT(updateline()));
- medit->insertItem("Copy ",e,SLOT(copy()),CTRL+Key_Insert);
- medit->insertItem("Paste ",e,SLOT(paste()), SHIFT+Key_Insert);
- medit->insertItem("Cut ",e,SLOT(cut()), CTRL+Key_Delete);
- medit->insertItem("Clear All ",e,SLOT(clear()));
- medit->insertSeparator();
- medit->insertItem("Find ",this,SLOT(findText()), CTRL+Key_F);
- medit->insertItem("Find Next ",this,SLOT(find_next()),CTRL+Key_L);
-
- msg = new QMultiLineEdit( this, "messages" );
- msg->setReadOnly(TRUE);
- compiler_path.sprintf("%s/%s",HomeDir,"compile/logcomp");
- gen_path.sprintf("%s/%s",HomeDir,"compile/gen");
- file_path.sprintf("%s",HomeDir);
-
- QFont f2("Times",14,QFont::Bold);
- e->setFont(f1);
- QColor col(200,200,200);
- QColorGroup grp(black,col,col.light(),col.dark(),col.dark(),black,col);
-
- msg->setPalette(QPalette(grp,grp,grp));
- position = new QLabel(this);
- position->setFont(f2);
- position->setFrameStyle(QFrame::NoFrame);
- position->setAutoResize(TRUE);
- resize(400,300);
-
-}
-