diff options
-rw-r--r-- | oovbaapi/ooo/vba/msforms/XComboBox.idl | 1 | ||||
-rw-r--r-- | oovbaapi/ooo/vba/msforms/XTextBox.idl | 1 | ||||
-rw-r--r-- | vbahelper/source/msforms/vbacombobox.cxx | 5 | ||||
-rw-r--r-- | vbahelper/source/msforms/vbacombobox.hxx | 1 | ||||
-rw-r--r-- | vbahelper/source/msforms/vbatextbox.cxx | 5 | ||||
-rw-r--r-- | vbahelper/source/msforms/vbatextbox.hxx | 1 |
6 files changed, 14 insertions, 0 deletions
diff --git a/oovbaapi/ooo/vba/msforms/XComboBox.idl b/oovbaapi/ooo/vba/msforms/XComboBox.idl index d4e57b2347a4..51ca4a4135d1 100644 --- a/oovbaapi/ooo/vba/msforms/XComboBox.idl +++ b/oovbaapi/ooo/vba/msforms/XComboBox.idl @@ -48,6 +48,7 @@ interface XComboBox [attribute] long EnterFieldBehavior; [attribute] long ListStyle; [attribute] long TextAlign; + [attribute, readonly] long TextLength; [attribute, readonly] XNewFont Font; void AddItem( [in] any pvargItem, [in] any pvargIndex ); diff --git a/oovbaapi/ooo/vba/msforms/XTextBox.idl b/oovbaapi/ooo/vba/msforms/XTextBox.idl index 7ea6ca62898c..267fbf7f01cb 100644 --- a/oovbaapi/ooo/vba/msforms/XTextBox.idl +++ b/oovbaapi/ooo/vba/msforms/XTextBox.idl @@ -44,6 +44,7 @@ interface XTextBox [attribute] boolean Multiline; [attribute] long SpecialEffect; [attribute] long BorderStyle; + [attribute, readonly] long TextLength; [attribute, readonly] XNewFont Font; }; diff --git a/vbahelper/source/msforms/vbacombobox.cxx b/vbahelper/source/msforms/vbacombobox.cxx index b0d1680e6101..9a75fa5cbaa1 100644 --- a/vbahelper/source/msforms/vbacombobox.cxx +++ b/vbahelper/source/msforms/vbacombobox.cxx @@ -230,6 +230,11 @@ void SAL_CALL ScVbaComboBox::setTextAlign( sal_Int32 /*nTextAlign*/ ) throw (uno { } +sal_Int32 SAL_CALL ScVbaComboBox::getTextLength() throw (uno::RuntimeException) +{ + return getText().getLength(); +} + uno::Reference< msforms::XNewFont > SAL_CALL ScVbaComboBox::getFont() throw (uno::RuntimeException) { return new VbaNewFont( this, mxContext, m_xProps ); diff --git a/vbahelper/source/msforms/vbacombobox.hxx b/vbahelper/source/msforms/vbacombobox.hxx index 922f6f63ca62..c73b617a743b 100644 --- a/vbahelper/source/msforms/vbacombobox.hxx +++ b/vbahelper/source/msforms/vbacombobox.hxx @@ -70,6 +70,7 @@ public: virtual void SAL_CALL setListStyle( sal_Int32 nListStyle ) throw (css::uno::RuntimeException); virtual sal_Int32 SAL_CALL getTextAlign() throw (css::uno::RuntimeException); virtual void SAL_CALL setTextAlign( sal_Int32 nTextAlign ) throw (css::uno::RuntimeException); + virtual sal_Int32 SAL_CALL getTextLength() throw (css::uno::RuntimeException); virtual css::uno::Reference< ov::msforms::XNewFont > SAL_CALL getFont() throw (css::uno::RuntimeException); // Methods diff --git a/vbahelper/source/msforms/vbatextbox.cxx b/vbahelper/source/msforms/vbatextbox.cxx index c9e4381f449a..b6aedcdceaf6 100644 --- a/vbahelper/source/msforms/vbatextbox.cxx +++ b/vbahelper/source/msforms/vbatextbox.cxx @@ -133,6 +133,11 @@ void SAL_CALL ScVbaTextBox::setBorderStyle( sal_Int32 /*nBorderStyle*/ ) throw ( { } +sal_Int32 SAL_CALL ScVbaTextBox::getTextLength() throw (uno::RuntimeException) +{ + return getText().getLength(); +} + uno::Reference< msforms::XNewFont > SAL_CALL ScVbaTextBox::getFont() throw (uno::RuntimeException) { return new VbaNewFont( this, mxContext, m_xProps ); diff --git a/vbahelper/source/msforms/vbatextbox.hxx b/vbahelper/source/msforms/vbatextbox.hxx index fb791db149e4..586bceb607a0 100644 --- a/vbahelper/source/msforms/vbatextbox.hxx +++ b/vbahelper/source/msforms/vbatextbox.hxx @@ -51,6 +51,7 @@ public: virtual void SAL_CALL setSpecialEffect( sal_Int32 nSpecialEffect ) throw (css::uno::RuntimeException); virtual sal_Int32 SAL_CALL getBorderStyle() throw (css::uno::RuntimeException); virtual void SAL_CALL setBorderStyle( sal_Int32 nBorderStyle ) throw (css::uno::RuntimeException); + virtual sal_Int32 SAL_CALL getTextLength() throw (css::uno::RuntimeException); virtual css::uno::Reference< ov::msforms::XNewFont > SAL_CALL getFont() throw (css::uno::RuntimeException); // XDefaultProperty rtl::OUString SAL_CALL getDefaultPropertyName( ) throw (css::uno::RuntimeException) { return ::rtl::OUString::createFromAscii("Value"); } |