diff --git a/doc/build/.doctrees/environment.pickle b/doc/build/.doctrees/environment.pickle index 4617a18..066104c 100644 Binary files a/doc/build/.doctrees/environment.pickle and b/doc/build/.doctrees/environment.pickle differ diff --git a/doc/build/.doctrees/main/calc.doctree b/doc/build/.doctrees/main/calc.doctree index c41aa63..3aa16a7 100644 Binary files a/doc/build/.doctrees/main/calc.doctree and b/doc/build/.doctrees/main/calc.doctree differ diff --git a/doc/build/_sources/main/calc.rst.txt b/doc/build/_sources/main/calc.rst.txt index 5e4f688..16109a3 100644 --- a/doc/build/_sources/main/calc.rst.txt +++ b/doc/build/_sources/main/calc.rst.txt @@ -163,26 +163,49 @@ Move * Move to position. +.. code-block:: python + sheet = doc[0] doc.move(sheet, 2) +* Move from sheet + +.. code-block:: python + + sheet = app.active_sheet + sheet.move() + +* Move to position. + +.. code-block:: python + + sheet = app.active_sheet + sheet.move(2) + Remove ~~~~~~ -* Remove by object +* Remove by object. .. code-block:: python sheet = doc[0] doc.remove(sheet) -* Remove by name +* Remove by name. .. code-block:: python doc.remove('One') +* Remove from sheet. + +.. code-block:: python + + sheet = app.active_sheet + sheet.remove() + Copy ~~~~ @@ -202,6 +225,13 @@ Copy doc.copy('Sheet1', 'Sheet2') +* From sheet + +.. code-block:: python + + sheet = app.active_sheet + sheet.copy(sheet.name + '_2') + Copy from ~~~~~~~~~ @@ -217,6 +247,27 @@ Copy from position = 0 doc.copy_from(doc_source, name_source, name_target, position) + +Copy to +~~~~~~~ + +* Copy from sheet with the same name + +.. code-block:: python + + doc = app.docs.new() + sheet = app.active_sheet + sheet.copy_to(doc) + +* Used new name + +.. code-block:: python + + doc = app.docs.new() + sheet = app.active_sheet + sheet.copy_to(doc, 'NewName') + + Sort ~~~~ @@ -266,3 +317,82 @@ Visible app.msgbox(sheet.visible) sheet.visible = not sheet.visible + +Is protected +~~~~~~~~~~~~ + +* If sheet is protected with password. + +.. code-block:: python + + sheet = app.active_sheet + app.msgbox(sheet.is_protected) + + +Set password +~~~~~~~~~~~~ + +.. code-block:: python + + sheet = app.active_sheet + sheet.password = 'letmein' + app.msgbox(sheet.is_protected) + + +Remove password +~~~~~~~~~~~~~~~ + +.. code-block:: python + + sheet = app.active_sheet + sheet.password = 'letmein' + app.msgbox(sheet.is_protected) + + sheet.unprotect('letmein') + app.msgbox(sheet.is_protected) + + +Tab color +~~~~~~~~~ + +.. code-block:: python + + sheet = app.active_sheet + app.msgbox(sheet.color) + + sheet.color = 'red' + app.msgbox(sheet.color) + + # RGB + sheet.color = (125, 200, 10) + app.msgbox(sheet.color) + + +Document parent +~~~~~~~~~~~~~~~ + +.. code-block:: python + + doc = sheet.doc + + +Activate +~~~~~~~~ + +.. code-block:: python + + doc = app.active + # Get last sheet + sheet = doc[-1] + + # Activate from doc + doc.activate(sheet) + + # Activate from sheet + sheet.activate() + + + + + + diff --git a/doc/build/main/calc.html b/doc/build/main/calc.html index c124ef7..3ed6de3 100644 --- a/doc/build/main/calc.html +++ b/doc/build/main/calc.html @@ -173,30 +173,50 @@
doc.move('Sheet1')
 
-
  • Writer