changeset: 17777:4601c4bdf3d4 bookmark: @ tag: qbase tag: qsci_2_7_mac_p04 tag: qtip tag: tip user: Torsten date: Sun Oct 27 22:19:45 2013 +0100 summary: [mq]: qsci_2_7_mac_p04 diff -r 8402768afd2d -r 4601c4bdf3d4 libgui/src/m-editor/file-editor-tab.cc --- a/libgui/src/m-editor/file-editor-tab.cc Sun Oct 27 22:05:50 2013 +0100 +++ b/libgui/src/m-editor/file-editor-tab.cc Sun Oct 27 22:19:45 2013 +0100 @@ -284,43 +284,6 @@ } } - _lexer_apis = new QsciAPIs(lexer); - if (_lexer_apis) - { - // get path to prepared api info - QDesktopServices desktopServices; - QString prep_apis_path - = desktopServices.storageLocation (QDesktopServices::HomeLocation) - + "/.config/octave/" + QString(OCTAVE_VERSION) + "/qsci/"; - _prep_apis_file = prep_apis_path + lexer->lexer () + ".pap"; - - if (!_lexer_apis->loadPrepared (_prep_apis_file)) - { // no prepared info loaded, prepare and save if possible - - // create raw apis info - QString keyword; - QStringList keyword_list; - int i,j; - for (i=1; i<=3; i++) // test the first 5 keyword sets - { - keyword = QString(lexer->keywords (i)); // get list - keyword_list = keyword.split (QRegExp ("\\s+")); // split - for (j = 0; j < keyword_list.size (); j++) // add to API - _lexer_apis->add (keyword_list.at (j)); - } - - // dsiconnect slot for saving prepared info if already connected - disconnect (_lexer_apis, SIGNAL (apiPreparationFinished ()), 0, 0); - // check whether path for prepared info exists or can be created - if (QDir("/").mkpath (prep_apis_path)) - { // path exists, apis info can be saved there - connect (_lexer_apis, SIGNAL (apiPreparationFinished ()), - this, SLOT (save_apis_info ())); - } - _lexer_apis->prepare (); // prepare apis info - } - } - QSettings *settings = resource_manager::get_settings (); if (settings) lexer->readSettings (*settings);