51 lines
786 B
ReStructuredText
51 lines
786 B
ReStructuredText
Document
|
|
~~~~~~~~
|
|
|
|
Current doc
|
|
^^^^^^^^^^^
|
|
|
|
.. code-block:: python
|
|
|
|
doc = app.active
|
|
app.msgbox(doc.type)
|
|
|
|
|
|
Selection
|
|
^^^^^^^^^
|
|
|
|
* If selection is range get LOCalcRange, if selection is shape get LOShape, other selection get original pyuno object.
|
|
|
|
.. code-block:: python
|
|
|
|
doc = app.active
|
|
selection = doc.selection
|
|
app.msgbox(type(selection))
|
|
|
|
|
|
Headers
|
|
^^^^^^^
|
|
|
|
* Hide or show columns and rows headers.
|
|
|
|
.. code-block:: python
|
|
|
|
doc = app.active
|
|
app.msgbox(doc.headers)
|
|
doc.headers = not doc.headers
|
|
app.msgbox(doc.headers)
|
|
doc.headers = not doc.headers
|
|
|
|
|
|
Tabs
|
|
^^^^
|
|
|
|
* Hide or show tab sheets.
|
|
|
|
.. code-block:: python
|
|
|
|
doc = app.active
|
|
app.msgbox(doc.tabs)
|
|
doc.tabs = not doc.tabs
|
|
app.msgbox(doc.tabs)
|
|
doc.tabs = not doc.tabs
|