diff options
author | Gergo Mocsi <gmocsi91@gmail.com> | 2013-07-31 17:08:18 +0200 |
---|---|---|
committer | Gergo Mocsi <gmocsi91@gmail.com> | 2013-09-02 18:16:53 +0200 |
commit | 27da1e7340c37c4cc098a367592da9e0ed42f7dc (patch) | |
tree | 7bbc86571dc65b85ab3d8da437732ce1f1736ef6 /basic | |
parent | GSOC work, config crach fix (diff) | |
download | core-27da1e7340c37c4cc098a367592da9e0ed42f7dc.tar.gz core-27da1e7340c37c4cc098a367592da9e0ed42f7dc.zip |
GSOC work, ListBox appearance fix (at the borders) + code fixes
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
Diffstat (limited to 'basic')
-rw-r--r-- | basic/Library_sb.mk | 4 | ||||
-rw-r--r-- | basic/source/classes/codecompletecache.cxx | 15 | ||||
-rw-r--r-- | basic/source/classes/sbxmod.cxx | 2 |
3 files changed, 19 insertions, 2 deletions
diff --git a/basic/Library_sb.mk b/basic/Library_sb.mk index b325a159bcb4..bf529a02f1ac 100644 --- a/basic/Library_sb.mk +++ b/basic/Library_sb.mk @@ -29,6 +29,10 @@ $(eval $(call gb_Library_set_include,sb,\ $(eval $(call gb_Library_use_external,sb,boost_headers)) +$(eval $(call gb_Library_use_custom_headers,sb,\ + officecfg/registry \ +)) + $(eval $(call gb_Library_use_sdk_api,sb)) $(eval $(call gb_Library_use_api,sb,oovbaapi)) diff --git a/basic/source/classes/codecompletecache.cxx b/basic/source/classes/codecompletecache.cxx index f48952f36394..57239ccc01f3 100644 --- a/basic/source/classes/codecompletecache.cxx +++ b/basic/source/classes/codecompletecache.cxx @@ -20,6 +20,7 @@ #include <basic/codecompletecache.hxx> #include <iostream> #include <rtl/instance.hxx> +#include <officecfg/Office/BasicIDE.hxx> namespace { @@ -27,12 +28,17 @@ namespace } CodeCompleteOptions::CodeCompleteOptions() -: bIsCodeCompleteOn( false ), +/*: bIsCodeCompleteOn( false ), bIsProcedureAutoCompleteOn( false ), bIsAutoCloseQuotesOn( false ), bIsAutoCloseParenthesisOn( false ), -bIsAutoCorrectSpellingOn( false ) +bIsAutoCorrectSpellingOn( false )*/ { + bIsAutoCorrectSpellingOn = officecfg::Office::BasicIDE::Autocomplete::AutoCorrectSpelling::get(); + bIsAutoCloseParenthesisOn = officecfg::Office::BasicIDE::Autocomplete::AutocloseParenthesis::get(); + bIsAutoCloseQuotesOn = officecfg::Office::BasicIDE::Autocomplete::AutocloseDoubleQuotes::get(); + bIsProcedureAutoCompleteOn = officecfg::Office::BasicIDE::Autocomplete::AutocloseProc::get(); + bIsCodeCompleteOn = officecfg::Office::BasicIDE::Autocomplete::CodeComplete::get(); } bool CodeCompleteOptions::IsCodeCompleteOn() @@ -50,6 +56,11 @@ bool CodeCompleteOptions::IsExtendedTypeDeclaration() return CodeCompleteOptions::IsCodeCompleteOn(); } +void CodeCompleteOptions::SetExtendedTypeDeclaration( const bool& b ) +{ + CodeCompleteOptions::SetCodeCompleteOn( b ); +} + bool CodeCompleteOptions::IsProcedureAutoCompleteOn() { return theCodeCompleteOptions::get().aMiscOptions.IsExperimentalMode() && theCodeCompleteOptions::get().bIsProcedureAutoCompleteOn; diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx index 989f5f547dae..053c13ed5ede 100644 --- a/basic/source/classes/sbxmod.cxx +++ b/basic/source/classes/sbxmod.cxx @@ -1795,6 +1795,7 @@ void SbModule::GetCodeCompleteDataFromParse(CodeCompleteDataCache& aCache) for( sal_uInt16 i = 0; i < pPool->GetSize(); ++i ) { SbiSymDef* pSymDef = pPool->Get(i); + //std::cerr << "i: " << i << ", type: " << pSymDef->GetType() << std::endl; if( pSymDef->GetType() == SbxOBJECT ) { if( !pParser->aGblStrings.Find( pSymDef->GetTypeId() ).isEmpty() ) @@ -1809,6 +1810,7 @@ void SbModule::GetCodeCompleteDataFromParse(CodeCompleteDataCache& aCache) for(sal_uInt16 j = 0; j < pChildPool.GetSize(); ++j ) { SbiSymDef* pChildSymDef = pChildPool.Get(j); + //std::cerr << "j: " << j << ", type: " << pChildSymDef->GetType() << std::endl; if( pChildSymDef->GetType() == SbxOBJECT ) { if( !pParser->aGblStrings.Find( pChildSymDef->GetTypeId() ).isEmpty() ) |