summaryrefslogtreecommitdiff
path: root/include/basic
AgeCommit message (Collapse)Author
2014-06-17improve the inlinesimplememberfunctions clang pluginNoel Grandin
Change-Id: I6d5a952901648e01904ef5c37f953c517304d31e
2014-06-09loplugin: inlinesimplememberfunctionsNoel Grandin
Change-Id: I42119f656ca528286fb25d2d36c0af54b7d04a6b
2014-05-29Detach all DocBasicItem objects upon process termination.Kohei Yoshida
To prevent rogue DocBasicItem objects (which are global objects) from attempting to stop listening after the main app is dead. Change-Id: I68a667137ca4e0eff18278f4d2d5dd67466eaf34
2014-04-14typo: hierarchie -> hierarchyThomas Arnhold
2014-04-07Replace SV_DECL/IMPL_REF macros with SvRef templateStephan Bergmann
Change-Id: I0ef2e67f6d61e0ce118c0f5e926b8194ef9d8058
2014-04-04StarBASIC::ErrorHdl sal_Bool->boolNoel Grandin
Change-Id: I68cc6c6b63174ff16e5fda00f62172e1eaacbf0d
2014-04-04SbxObject::Call sal_Bool->boolNoel Grandin
Change-Id: I2e52ddf704679a118fbbc4efebb7cf9fb36f0c34
2014-04-04SbxObject::isClass sal_Bool->boolNoel Grandin
Change-Id: I71f7b3603df43924d7374969444b929e1eecca4e
2014-04-01Explicitly mark overriding destructors as "virtual"Stephan Bergmann
It appears that the C++ standard allows overriding destructors to be marked "override," but at least some MSVC versions complain about it, so at least make sure such destructors are explicitly marked "virtual." Change-Id: I0e1cafa7584fd16ebdce61f569eae2373a71b0a1
2014-03-28fdo#75280 Started cleaning up of sal_uIntPtr usage.Valentin Kettner
Converted wrong usage of sal_uIntPtr to appropriate other types in basic module. The bug is not fully fixed with this since many other occurences of sal_uIntPtr remain. Update due to code review comments: Fixed forgetting to change some declarations in iosys.cxx. Cleaned up the one remaining sal_uIntPtr in iosys.cxx Fixed adding a sal_uInt64 to a Date (uses long now instead) in methods.cxx Fixed the VarDecFromUI4 call in sbxdec.cxx from sal_uLong to ULONG . Conflicts: basic/source/runtime/iosys.cxx Change-Id: Ia6460be04967deb68b92eb62d945da8814fae605
2014-03-28Remove remaining DBG_CTOR etc. remnants from basicStephan Bergmann
Change-Id: Ia714029c2e32e28c1bb6f4f59d0c7f357eccc236
2014-03-27basic: sal_Bool->boolNoel Grandin
Change-Id: Icd78d21495f305c8f00280eee76e7262e542317d
2014-03-27basic: sal_Bool->boolNoel Grandin
Change-Id: Id4952b6f97f9e8f917fea5651dee91499d109e48
2014-03-27basic: sal_Bool->boolNoel Grandin
Change-Id: Idfe18863b2c6f60da5192d661f66e85a2bac09e5
2014-03-26First batch of adding SAL_OVERRRIDE to overriding function declarationsStephan Bergmann
...mostly done with a rewriting Clang plugin, with just some manual tweaking necessary to fix poor macro usage. Change-Id: I71fa20213e86be10de332ece0aa273239df7b61a
2014-03-26Split TYPEINFO into plain and TYPEINFO_OVERRIDEStephan Bergmann
...where the latter contains SAL_OVERRIDE annotations Change-Id: Id64794b388d83dfe7026440e8b20a5b5efd412d1
2014-03-13basic: prefer passing OUString and OString by referenceNoel Grandin
Change-Id: I8121204cdb37d4e1d8967397f3e45bdab6aaddad
2014-03-01Remove visual noise from includeAlexander Wilms
Conflicts: include/framework/preventduplicateinteraction.hxx include/sfx2/sfxbasecontroller.hxx include/sfx2/sfxbasemodel.hxx include/toolkit/awt/vclxtabpagemodel.hxx include/vcl/field.hxx include/vcl/settings.hxx Change-Id: Ibccf9f88c68267a3d7e656012b51eaf644c418c2 Reviewed-on: https://gerrit.libreoffice.org/8272 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2014-02-28remove unused code in basic/CodeCompleteDataCacheNoel Grandin
Specifically: CodeCompleteDataCache::GetVars() const CodeCompleteDataCache::SetVars(boost::unordered_map const&) CodeCompleteDataCache::print() const Change-Id: I59fb6f50ff47747c3cac959302bf6b7c4f4d79d3
2014-02-26cppuhelper: retrofit std::exception into overriding exception specsStephan Bergmann
Change-Id: I56e32131b7991ee9948ce46765632eb823d463b3
2014-01-30fdo#63154 Removed unused solar.h ref. in basic and formulaAlexandre Vicenzi
Change-Id: Ibf30f29653568929e65ebd897cef474a6838d5cc Reviewed-on: https://gerrit.libreoffice.org/7735 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2013-12-11sbxbase.hxx is private to basicTor Lillqvist
Change-Id: I108bd247a40ce2b46034cabe8b075fa4f5a396df
2013-12-11sbstdobj.hxx is private to basicTor Lillqvist
Change-Id: I131dfeded783edfea94208d1cf8d70a2090785fa
2013-12-11sbprop.hxx is private to basicTor Lillqvist
Change-Id: I1d7a28652ee7743b6823d78e1565338a324f0a6a
2013-12-11sbobjmod.hxx is private to basicTor Lillqvist
Change-Id: I4ad28b049de5f7268ee1ca2e8992e2f29ed05380
2013-12-11basic/global.hxx is private to basicTor Lillqvist
Change-Id: I90a28e34eb45819e240931cd751ac0a546ea6be8
2013-11-09fdo#65108 inter-module includes <>Norbert Thiebaud
Change-Id: I419a1288bc6120d978fc301f127d5d29298f3ede
2013-10-23fixincludeguards.sh: include/{basegfx,basic}Thomas Arnhold
Change-Id: Id18d3f4b4ed763b2ec9e718d66c3c3b9968fcac2
2013-09-26typo fixes in commentsAndras Timar
Change-Id: Iaadec33715f8e0e0c6595c5e684606905274fdab
2013-09-11Easier conversion between Basic Date and UNO Date/TimeLionel Elie Mamane
Utility functions to convert between Basic Date type and the representations of Date and Time in UNO, namely: - com.sun.star.util.Date - com.sun.star.util.Time - com.sun.star.util.DateTime Name of new functions: - CDateToUnoDate - CDateFromUnoDate - CDateToUnoTime - CDateFromUnoTime - CDateToUnoDateTime - CDateFromUnoDateTime Change-Id: I2b971df20df1c0351d071023e042169b548894f1 Reviewed-on: https://gerrit.libreoffice.org/5897 Reviewed-by: Noel Power <noel.power@suse.com> Tested-by: Noel Power <noel.power@suse.com>
2013-09-03completition->completion :)Ivan Timofeev
Change-Id: I7a5ae7cc0d6a253bbc27db076babedd65c89be1a
2013-09-02GSOC work, autocorrect procedures+variablesGergo Mocsi
Fixed some small issue with the right arrow key in the ListBox. Autocorrection now correct all variable types and procedure names. Change-Id: Iff1abaf10c621aef04772837faa272bb6f987e37
2013-09-02GSOC work, renaming + options fixGergo Mocsi
Options now work correctly: I've added the missing function. Rename: renamed some variables and methods to kep the consistence( Autocorrect keywords -> Autocorrect). Change-Id: I6b4914575f1a06eb3268c133b8b990364e3d24e4
2013-09-02GSOC work, behavior fixesGergo Mocsi
Code completition: left/right arrow keys handled. Left arrow dismisses the dialog when reaches the dot. Right arrow dismissed the dialog when reaches the next line. ListBox appearance fixed. TAB key can insert the first matching entry. Autocorrect: "Autocorrect Keywords" has been renamed to "Autcorrect" (in the UI, and the config file, after this patch a make dev-install is needed). Keyword case correction is not just capitalizing the first letter ( eg. Elseif -> ElseIf ). Autoclose procedures: cursor is being placed inside the preocedure. Change-Id: Ie7e9ae96b49bd94562db83f96e1c4ad63ab3f3d6
2013-09-02GSOC work, renaming for consistencyGergo Mocsi
Menu enrty was renamed to IDE Options under View. SID_BASICIDE_CODECOMPLETE was renamed to SID_BASICIDE_IDEOPTIONS. CodeCompleteDlg was rename to BasicIDEOptionDlg. Ui file was renamed to basicideoptionsdialog.ui. Checkbox for extended types is now independent from code complete one. Change-Id: Id862df0ee56cdf2aa81e19a34099fe679ad5d311
2013-09-02GSOC work, ListBox appearance fix (at the borders) + code fixesGergo Mocsi
ListBox appearance fixed at the borders: a) bottom: it it placed over the current line (not under) b) right side: listbox's right side is adjusted to the window's right side Coed fixes: CodeCompleteOptions now intializes itself from the configuration file BasicIDE.xcs Added a checkbox for enabling extended types in the options dialog. Cursor is visible when the listbox is active. Fixed the small issue when deleting a character. Change-Id: I68b80143de245cebfce65cdd8af37ea4694aa81b
2013-09-02GSOC work, "autocomplete procedures" fix + new featureGergo Mocsi
Fixed the procedure autoclose function. Now, autoclose is based on the syntax higlighter: if finds an opening token, starts searching forward to a close token. If there is another sub/function keyword, or EOF is reached, the procedure is considered incomplete. If the end token is found, the procedure is considered to be closed. Added function autocorrect symbol spelling, wich corrects the ascii case of the keywords, and corrects the spelling of the extended types. Change-Id: Ibd17f319a6d6ff5c3f91f4adb7a10dc701f0468a
2013-09-02GSOC work, nested reflection fix - againGergo Mocsi
Fixed the issue when an invalid method was typed, listbox showed tha methods of the base variable. Change-Id: I88576645b373e76112103055d547f713af1fc153
2013-09-02GSOC work, implement "Autoclose parenthesis" functionGergo Mocsi
Autoclosing parenthesis function is working. Implementation is similar to autoclosing double quotes, except that this one does not need the HighlighPortion struct to use. Renamed the checkbox title to "Autoclose parenthesis". Change-Id: I4311cd8020f0dc0b62a2d8707e0eccbf57e0d2c2
2013-09-02GSOC work, implemented "Autoclose Double Quotes" optionGergo Mocsi
Feature autoclosing double quotes (strings) implemented. When the user presses the '"' key, it's pair is also being inserted (only when the previous character is also a '"'), and the cursor is being placed inside the two quotes. Also, if the there was a string (like: "aaa""), the second one is not inserted. Change-Id: I3e4a5e426d2d4bdbf56899fe3e36359ae161b52a
2013-09-02GSOC work, procedure autoclose implementationGergo Mocsi
Now, function procedure autoclose is working. Created a struct named IncompleteProcData to store the line number, type and name of the inclomplete procedure. Procedures are store in a vector (IncompleteProcedures), and are as a member in SbModule. I've created a function called SbModule::GetIncompleteProcedures() to extract the data. Data extraction uses SbModule::SetSource32, beacuse that one tokenizes sthe source file, and recognizes procedures. Closing procedures is triggered ky pressing the Enter key when typing. It checks the actual sub, and if it's incomplete, adds the correct ending( End Sub/End Function). There is only one problem: function SbModule::SetSource32 is not too often calle, maybe extraction should be done by a timer. Change-Id: Id88daaef329e8b5c194b765c5261d356bfb3a0c9
2013-09-02GSOC work, cache implementation fix, code fixesGergo Mocsi
The CodeCompleteDataCache got a new implementation: global variables are stored separately. The "static const" OUString-s were removed from the class. Data extraction is only done when pressing the dot key. Change-Id: I3ff94c0c6eabe328761336d4c74744eb7efc6056
2013-09-02GSOC work, ModalDialog instead of menu entryGergo Mocsi
Created a ModalDialog named CodeCompleteOptionsDlg to edit options for code completition/suggestion. Unimplemented features in it are disabled. The dialog window uses Glade .ui file. Change-Id: I1b59f386a9575aa25b38c5a1d7d1f020498a69ab
2013-09-02GSOC work, code complete option, menu entry fixesGergo Mocsi
Menu entry is added under View->Enable Code Completition when in Experimental mode. Fixed the call of funtion SbModule::GetCodeCompleteDataFromParse() to be called only when code completition is enabled. Replaced the occurences of SvtMiscOptions to CodeCompleteOptions. Change-Id: If0520123ab5f612d7d24fb98f8e9bf6881af76cb
2013-09-02GSOC work menu entry + code fixGergo Mocsi
Fixed the definition of GLOB_KEY, NOT_FOUND from const to static const. Added a new menu entry for code completition under View->Enable Code Completition. Change-Id: If8ac25ee43a7ba780ccdee2e5e909777115a1f27
2013-09-02GSOC work, some code fixesGergo Mocsi
Fixed the link error: declared CodeCompleteDataCache as BASIC_DLLPUBLIC and it worked fine. Fixed sergmentation fault error in CodeCompleteWindow. The new cache implementation is fully functional. CodeCompleteWindow is now being used as boost::scoped_ptr. Change-Id: I76a0fc7407d589e7f94280fc4d50cea51b9639db
2013-09-02GSOC work, code fixes + cache implementationGergo Mocsi
WARNING: cache implementation gives a link error to it's methods. Created the cache called CodeCompleteDataCache in file include/basic/codecompletecache.hxx This class should replace the std::vector< CodeCompleteData > int file baside2b.cxx When issuing command "make basic", it compiles fine, but, when "make basctl", it gives a link error (ld returned status 1) to CodeCompleteDataCache's methods. Change-Id: If78c6533b7fb5653cc459d22b80c98d097b886eb
2013-09-02GSOC work week 5, some recent fixesGergo Mocsi
This week I've managed to fix the ListBox appearance. Also, I've modified the code: it gets the data on insert/remove/change, and gets updated only when the dot is pressed. This makes the data to be up-to-date. Next, I wrote a Split(OUString , char) function to do the nested reflection (It works, but it will need some tweaks later). Also, code generation is disabled for code completition (just a boolean value, maybe it could be done in a more "elegant" way, like the error supression). Change-Id: I43d250c0a065351950ac6424dcd88266d70bcef3
2013-09-02GSOC work week 2, getting infromation from variables and print on terminalGergo Mocsi
This is an early version. I use the BASIC parser to parse the source, then the infromation is extracted from the symbol table built by parser. Error reporting is suppressed, beacuse it is not needed fro code completition. I placed my function inside SbModule, and created a struct called CodeCompletitionData, which holds the object's name, it's parent, and it's type name. This function, SbMethod::GetCodeCompleteDataFromParse() is called from Basic IDE's Notify function, which updates a cache(actually, reassigns a viariable :) ). Later, in the EditorWindow::KeyInput function there is a check wheteher dot key is pressed. After that, the actual variable (or word) is being looked up in the vector that holds code completition data. And finally, if it is found, it's methods are printed on the terminal. Change-Id: Idaf19baa8f720b8b117a76dc3cc2f90dd04fd155
2013-07-26targetted clean of redundant header piece from 62badf3828Michael Meeks
Change-Id: Ic1240114d667fb7797afae4847427cc889f3cb48