r23382 by jghali - Some fixes for scripter documentation

scribus-commit scribus-commit at lists.scribus.net
Wed Nov 27 00:02:13 UTC 2019


Author: jghali
Date: Wed Nov 27 00:02:13 2019
New Revision: 23382

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=23382
Log:
Some fixes for scripter documentation

Modified:
    trunk/Scribus/doc/de/scripterapi-page.html
    trunk/Scribus/doc/en/scripterapi-page.html
    trunk/Scribus/doc/it/scripterapi-page.html
    trunk/Scribus/doc/ru/scripterapi-page.html

Modified: trunk/Scribus/doc/de/scripterapi-page.html
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23382&path=/trunk/Scribus/doc/de/scripterapi-page.html
==============================================================================
--- trunk/Scribus/doc/de/scripterapi-page.html	(original)
+++ trunk/Scribus/doc/de/scripterapi-page.html	Wed Nov 27 00:02:13 2019
@@ -12,7 +12,7 @@
 <dl>
 
 <dt><a name="-applyMasterPage"><strong>applyMasterPage</strong>(...)</a></dt>
-<dd><code>applyMasterPage(Master Page name, page nr)</code>
+<dd><code>applyMasterPage(masterPageName, pageNr)</code>
 <p>Applies the named master page to the indicated page. Some examples of usage are on the wiki.</a>.</p></dd>
 
 <dt><a name="-closeMasterPage"><strong>closeMasterPage</strong>(...)</a></dt>
@@ -26,7 +26,11 @@
 
 <dt><a name="-currentPage"><strong>currentPage</strong></a>(...)</dt>
 <dd><code>currentPage() -> integer</code>
-<p>Returns the number of the current working page. Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is.</p></dd>
+<p>Returns the number of the current working page. Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is.</p>
+<p>If you want to enter into a text frame the special character for the current page number, it is decimal 30 or hex 0x1e. For example, either of the following would be equivalent:</p></dd>
+<dd><p><b>scribus.setText('Page ' + chr(30), textframe)</b></p></dd>
+<dd><p><b>scribus.setText('Page \x1e', textframe)</b></p></dd>
+<dd><p>See also <strong>pageCount()</strong></dd>
 
 <dt><a name="-deleteMasterPage"><strong>deleteMasterPage</strong>(...)</a></dt>
 <dd><code>deleteMasterPage(pageName)</code>
@@ -81,12 +85,12 @@
 
 <dt><a name="-gotoPage"><strong>gotoPage</strong></a>(...)</dt>
 <dd><code>gotoPage(nr)</code>
-<p>Moves to the page "nr" (that is, makes the current page "nr"). Note that gotoPage doesn't (curently) change the page the user's view is displaying, it just sets the page that script commands will operates on.</p>
+<p>Moves to the page "nr" (that is, makes the current page "nr"). Note that gotoPage doesn't (currently) change the page the user's view is displaying, it just sets the page that script commands will operates on.</p>
 <p>May raise IndexError if the page number is out of range.</p></dd>
 
 <dt><a name="-importPage"><strong>importPage</strong>(...)</a></dt>
 <dd><code></code>
-<p>importPage("fromDoc", (pageList), [create, imortwhere, importwherePage]) Imports a set of pages (given as a tuple) from an existing document (the file name must be given). This functions maps the "Page->Import" dropdown menu function. fromDoc: string; the filename of the document to import pages from pageList: tuple with page numbers of pages to import create: number; 0 to replace existing pages, 1 (default) to insert new pages importWhere: number; the page number (of the current document) at which import the pages importWherePage: number; used if create==1; 0 to create pages before selected page; 1 to create pages after selected page; 2 (default) to create pages at the end of the document</p></dd>
+<p>importPage("fromDoc", (pageList), [create, importwhere, importwherePage]) Imports a set of pages (given as a tuple) from an existing document (the file name must be given). This functions maps the "Page->Import" dropdown menu function. fromDoc: string; the filename of the document to import pages from pageList: tuple with page numbers of pages to import create: number; 0 to replace existing pages, 1 (default) to insert new pages importWhere: number; the page number (of the current document) at which import the pages importWherePage: number; used if create==1; 0 to create pages before selected page; 1 to create pages after selected page; 2 (default) to create pages at the end of the document</p></dd>
 
 <dt><a name="-newPage"><strong>newPage</strong></a>(...)</dt>
 <dd><code>newPage(where [,"masterpage"])</code>
@@ -95,7 +99,10 @@
 	
 <dt><a name="-pageCount"><strong>pageCount</strong></a>(...)</dt>
 <dd><code>pageCount() -> integer</code>
-<p>Returns the number of pages in the document.</p></dd>
+<p>Returns the number of pages in the document.</p>
+<p>There is also a special character for page count, in decimal 23, and in hex 0x17. You might combine this with the special character for current page in a text frame (on a Master Page for example) as follows. Either of these is equivalent:</p></dd>
+<dd><p><b>scribus.setText('Page ' + chr(30) + ' of ' + chr(23), textframe)</b></p>
+<p><b>scribus.setText('Page \x1e of \x17', textframe)</p></b></dd>
 
 <dt><a name="-redrawAll"><strong>redrawAll</strong></a>(...)</dt>
 <dd><code>redrawAll()</code>
@@ -109,8 +116,9 @@
 <dt><a name="-setHGuides"><strong>setHGuides</strong></a>(...)</dt>
 <dd><code>setHGuides(list)</code>
 <p>Sets horizontal guides. Input parameter must be a list of guide positions measured in the current document units - see UNIT_<type> constants.</p>
-<p>Example: <a href="#-setHGuides">setHGuides</a>(<a href="#-getHGuides">getHGuides</a>() + [200.0, 210.0] # add new guides without any lost<br>
-<a href="#-setHGuides">setHGuides</a>([90,250]) # replace current guides entirely</p></dd>
+<p>Example:</p>
+<p><b>setHGuides(getHGuides() + [200.0, 210.0])</b> # this will add new guides while saving existing guides</p>
+<p><b>setHGuides([90,250])</b> # this will replace current guides entirely</p></dd>
 
 <dt><a name="-setRedraw"><strong>setRedraw</strong></a>(...)</dt>
 <dd><code>setRedraw(bool)</code>
@@ -118,7 +126,7 @@
 
 <dt><a name="-setVGuides"><strong>setVGuides</strong></a>(...)</dt>
 <dd><code>setVGuides()</code>
-<p>See <a href="#-setHGuides">setHGuides</a>.</p></dd>
+<p>The usage is analagous to that of <a href="#-setHGuides">setHGuides</a> for either adding to existing guides or replacing them.</p></dd>
 
 </dl>
 </body>

Modified: trunk/Scribus/doc/en/scripterapi-page.html
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23382&path=/trunk/Scribus/doc/en/scripterapi-page.html
==============================================================================
--- trunk/Scribus/doc/en/scripterapi-page.html	(original)
+++ trunk/Scribus/doc/en/scripterapi-page.html	Wed Nov 27 00:02:13 2019
@@ -12,7 +12,7 @@
 <dl>
 
 <dt><a name="-applyMasterPage"><strong>applyMasterPage</strong>(...)</a></dt>
-<dd><code>applyMasterPage(Master Page name, page nr)</code>
+<dd><code>applyMasterPage(masterPageName, pageNr)</code>
 <p>Applies the named master page to the indicated page. Some examples of usage are on the wiki.</a>.</p></dd>
 
 <dt><a name="-closeMasterPage"><strong>closeMasterPage</strong>(...)</a></dt>

Modified: trunk/Scribus/doc/it/scripterapi-page.html
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23382&path=/trunk/Scribus/doc/it/scripterapi-page.html
==============================================================================
--- trunk/Scribus/doc/it/scripterapi-page.html	(original)
+++ trunk/Scribus/doc/it/scripterapi-page.html	Wed Nov 27 00:02:13 2019
@@ -1,118 +1,133 @@
-<html>
-<head>
-	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
-	<title>Page related Commands</title>
-</head>
-<body>
-<h2>Page related Commands</h2>
-
-<dl>
-
-<dt><a name="-closeMasterPage"><strong>closeMasterPage</strong>(...)</a></dt>
-<dd><code>closeMasterPage()</code>
-<p>Closes the currently active master page, if any, and returns editing
-to normal. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
-
-<dt><a name="-createMasterPage"><strong>createMasterPage</strong>(...)</a></dt>
-<dd><code>createMasterPage(pageName)</code>
-<p>Creates a new master page named pageName. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
-
-<dt><a name="-currentPage"><strong>currentPage</strong></a>(...)</dt>
-<dd><code>currentPage() -> integer</code>
-<p>Returns the number of the current working page. Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is.</p></dd>
-
-<dt><a name="-deleteMasterPage"><strong>deleteMasterPage</strong>(...)</a></dt>
-<dd><code>deleteMasterPage(pageName)</code>
-<p>Delete the named master page.</p></dd>
-
-<dt><a name="-deletePage"><strong>deletePage</strong></a>(...)</dt>
-<dd><code>deletePage(nr)</code>
-<p>Deletes the given page. Does nothing if the document contains only one page. Page numbers are counted from 1 upwards, no matter what the displayed first page number is.</p>
-<p>May raise IndexError if the page number is out of range</p></dd>
-
-<dt><a name="-editMasterPage"><strong>editMasterPage</strong>(...)</a></dt>
-<dd><code>editMasterPage(pageName)</code>
-<p>Enables master page editing and opens the named master page
-for editing. Finish editing with <a href="#-closeMasterPage">closeMasterPage()</a>.</p></dd>
-
-<dt><a name="-getAllObjects"><strong>getAllObjects</strong></a>(...)</dt>
-<dd><code>getAllObjects() -> list</code>
-<p>Returns a list containing the names of all objects on the current page.</p></dd>
-
-<dt><a name="-getHGuides"><strong>getHGuides</strong></a>(...)</dt>
-<dd><code>getHGuides() -> list</code>
-<p>Returns a list containing positions of the horizontal guides. Values are in the
-document's current units - see UNIT_<type> constants.</p></dd>
-
-<dt><a name="-getPageType"><strong>getPageType</strong>(...)</a></dt>
-<dd><code>getPageType() -> integer</code>
-<p>Returns the type of the Page, 0 means left Page, 1 is a middle Page and 2 is a right Page</p></dd>
-
-<dt><a name="-getVGuides"><strong>getVGuides</strong></a>(...)</dt>
-<dd><code>getVGuides()</code>
-<p>See <a href="#-getHGuides">getHGuides</a>.</p></dd>
-
-<dt><a name="-getPageItems"><strong>getPageItems</strong></a>(...)</dt>
-<dd><code>getPageItems() -> list</code>
-<p>Returns a list of tuples with items on the current page. The tuple is: (name, objectType, order) E.g. [('Text1', 4, 0), ('Image1', 2, 1)] means that object named 'Text1' is a text frame (type 4) and is the first at the page...</p></dd>
-
-<dt><a name="-getPageMargins"><strong>getPageMargins</strong></a>(...)</dt>
-<dd><code>getPageMargins()</code>
-<p>Returns the document page margins as a (top, left, right, bottom) tuple in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
-
-<dt><a name="-getPageNMargins"><strong>getPageNMargins</strong></a>(...)</dt>
-<dd><code>getPageNMargins(nr)</code>
-<p>Returns a tuple with a particular page's margins measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
-
-<dt><a name="-getPageSize"><strong>getPageSize</strong></a>(...)</dt>
-<dd><code>getPageSize() -> tuple</code>
-<p>Returns a tuple with document page dimensions measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
-
-<dt><a name="-getPageNSize"><strong>getPageNSize</strong></a>(...)</dt>
-<dd><code>getPageNSize(nr) -> tuple</code>
-<p>Returns a tuple with a particular page's size measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
-
-<dt><a name="-gotoPage"><strong>gotoPage</strong></a>(...)</dt>
-<dd><code>gotoPage(nr)</code>
-<p>Moves to the page "nr" (that is, makes the current page "nr"). Note that gotoPage doesn't (curently) change the page the user's view is displaying, it just sets the page that script commands will operates on.</p>
-<p>May raise IndexError if the page number is out of range.</p></dd>
-
-<dt><a name="-importPage"><strong>importPage</strong>(...)</a></dt>
-<dd><code></code>
-<p>importPage("fromDoc", (pageList), [create, imortwhere, importwherePage]) Imports a set of pages (given as a tuple) from an existing document (the file name must be given). This functions maps the "Page->Import" dropdown menu function. fromDoc: string; the filename of the document to import pages from pageList: tuple with page numbers of pages to import create: number; 0 to replace existing pages, 1 (default) to insert new pages importWhere: number; the page number (of the current document) at which import the pages importWherePage: number; used if create==1; 0 to create pages before selected page; 1 to create pages after selected page; 2 (default) to create pages at the end of the document</p></dd>
-
-<dt><a name="-newPage"><strong>newPage</strong></a>(...)</dt>
-<dd><code>newPage(where [,"masterpage"])</code>
-<p>Creates a new page. If "where" is -1 the new Page is appended to the document, otherwise the new page is inserted before "where". Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is. The optional parameter "masterpage" specifies the name of the master page for the new page.</p>
-<p>May raise IndexError if the page number is out of range</p></dd>
-	
-<dt><a name="-pageCount"><strong>pageCount</strong></a>(...)</dt>
-<dd><code>pageCount() -> integer</code>
-<p>Returns the number of pages in the document.</p></dd>
-
-<dt><a name="-redrawAll"><strong>redrawAll</strong></a>(...)</dt>
-<dd><code>redrawAll()</code>
-<p>Redraws all pages.</p></dd>
-
-<dt><a name="-savePageAsEPS"><strong>savePageAsEPS</strong></a>(...)</dt>
-<dd><code>savePageAsEPS("name")</code>
-<p>Saves the current page as an EPS to the file "name".</p>
-<p>May raise ScribusError if the save failed.</p></dd>
-
-<dt><a name="-setHGuides"><strong>setHGuides</strong></a>(...)</dt>
-<dd><code>setHGuides(list)</code>
-<p>Sets horizontal guides. Input parameter must be a list of guide positions measured in the current document units - see UNIT_<type> constants.</p>
-<p>Example: <a href="#-setHGuides">setHGuides</a>(<a href="#-getHGuides">getHGuides</a>() + [200.0, 210.0] # add new guides without any lost<br>
-<a href="#-setHGuides">setHGuides</a>([90,250]) # replace current guides entirely</p></dd>
-
-<dt><a name="-setRedraw"><strong>setRedraw</strong></a>(...)</dt>
-<dd><code>setRedraw(bool)</code>
-<p>Disables page redraw when bool = False, otherwise redrawing is enabled. This change will persist even after the script exits, so make sure to call <a href="#-setRedraw">setRedraw</a>(True) in a finally: clause at the top level of your script.</p></dd>
-
-<dt><a name="-setVGuides"><strong>setVGuides</strong></a>(...)</dt>
-<dd><code>setVGuides()</code>
-<p>See <a href="#-setHGuides">setHGuides</a>.</p></dd>
-
-</dl>
-</body>
-</html>
+<html>
+<head>
+	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+	<title>Page related Commands</title>
+</head>
+<style>
+ at import "manual.css";
+</style>
+<body>
+<h2>Page related Commands</h2>
+
+<dl>
+
+<dt><a name="-applyMasterPage"><strong>applyMasterPage</strong>(...)</a></dt>
+<dd><code>applyMasterPage(masterPageName, pageNr)</code>
+<p>Applies the named master page to the indicated page. Some examples of usage are on the wiki.</a>.</p></dd>
+
+<dt><a name="-closeMasterPage"><strong>closeMasterPage</strong>(...)</a></dt>
+<dd><code>closeMasterPage()</code>
+<p>Closes the currently active master page, if any, and returns editing
+to normal. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
+
+<dt><a name="-createMasterPage"><strong>createMasterPage</strong>(...)</a></dt>
+<dd><code>createMasterPage(pageName)</code>
+<p>Creates a new master page named pageName. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
+
+<dt><a name="-currentPage"><strong>currentPage</strong></a>(...)</dt>
+<dd><code>currentPage() -> integer</code>
+<p>Returns the number of the current working page. Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is.</p>
+<p>If you want to enter into a text frame the special character for the current page number, it is decimal 30 or hex 0x1e. For example, either of the following would be equivalent:</p></dd>
+<dd><p><b>scribus.setText('Page ' + chr(30), textframe)</b></p></dd>
+<dd><p><b>scribus.setText('Page \x1e', textframe)</b></p></dd>
+<dd><p>See also <strong>pageCount()</strong></dd>
+
+<dt><a name="-deleteMasterPage"><strong>deleteMasterPage</strong>(...)</a></dt>
+<dd><code>deleteMasterPage(pageName)</code>
+<p>Delete the named master page.</p></dd>
+
+<dt><a name="-deletePage"><strong>deletePage</strong></a>(...)</dt>
+<dd><code>deletePage(nr)</code>
+<p>Deletes the given page. Does nothing if the document contains only one page. Page numbers are counted from 1 upwards, no matter what the displayed first page number is.</p>
+<p>May raise IndexError if the page number is out of range</p></dd>
+
+<dt><a name="-editMasterPage"><strong>editMasterPage</strong>(...)</a></dt>
+<dd><code>editMasterPage(pageName)</code>
+<p>Enables master page editing and opens the named master page
+for editing. Finish editing with <a href="#-closeMasterPage">closeMasterPage()</a>.</p></dd>
+
+<dt><a name="-getAllObjects"><strong>getAllObjects</strong></a>(...)</dt>
+<dd><code>getAllObjects() -> list</code>
+<p>Returns a list containing the names of all objects on the current page.</p></dd>
+
+<dt><a name="-getHGuides"><strong>getHGuides</strong></a>(...)</dt>
+<dd><code>getHGuides() -> list</code>
+<p>Returns a list containing positions of the horizontal guides. Values are in the
+document's current units - see UNIT_<type> constants.</p></dd>
+
+<dt><a name="-getPageType"><strong>getPageType</strong>(...)</a></dt>
+<dd><code>getPageType() -> integer</code>
+<p>Returns the type of the Page, 0 means left Page, 1 is a middle Page and 2 is a right Page</p></dd>
+
+<dt><a name="-getVGuides"><strong>getVGuides</strong></a>(...)</dt>
+<dd><code>getVGuides()</code>
+<p>See <a href="#-getHGuides">getHGuides</a>.</p></dd>
+
+<dt><a name="-getPageItems"><strong>getPageItems</strong></a>(...)</dt>
+<dd><code>getPageItems() -> list</code>
+<p>Returns a list of tuples with items on the current page. The tuple is: (name, objectType, order) E.g. [('Text1', 4, 0), ('Image1', 2, 1)] means that object named 'Text1' is a text frame (type 4) and is the first at the page...</p></dd>
+
+<dt><a name="-getPageMargins"><strong>getPageMargins</strong></a>(...)</dt>
+<dd><code>getPageMargins()</code>
+<p>Returns the document page margins as a (top, left, right, bottom) tuple in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
+
+<dt><a name="-getPageNMargins"><strong>getPageNMargins</strong></a>(...)</dt>
+<dd><code>getPageNMargins(nr)</code>
+<p>Returns a tuple with a particular page's margins measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
+
+<dt><a name="-getPageSize"><strong>getPageSize</strong></a>(...)</dt>
+<dd><code>getPageSize() -> tuple</code>
+<p>Returns a tuple with document page dimensions measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
+
+<dt><a name="-getPageNSize"><strong>getPageNSize</strong></a>(...)</dt>
+<dd><code>getPageNSize(nr) -> tuple</code>
+<p>Returns a tuple with a particular page's size measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
+
+<dt><a name="-gotoPage"><strong>gotoPage</strong></a>(...)</dt>
+<dd><code>gotoPage(nr)</code>
+<p>Moves to the page "nr" (that is, makes the current page "nr"). Note that gotoPage doesn't (currently) change the page the user's view is displaying, it just sets the page that script commands will operates on.</p>
+<p>May raise IndexError if the page number is out of range.</p></dd>
+
+<dt><a name="-importPage"><strong>importPage</strong>(...)</a></dt>
+<dd><code></code>
+<p>importPage("fromDoc", (pageList), [create, importwhere, importwherePage]) Imports a set of pages (given as a tuple) from an existing document (the file name must be given). This functions maps the "Page->Import" dropdown menu function. fromDoc: string; the filename of the document to import pages from pageList: tuple with page numbers of pages to import create: number; 0 to replace existing pages, 1 (default) to insert new pages importWhere: number; the page number (of the current document) at which import the pages importWherePage: number; used if create==1; 0 to create pages before selected page; 1 to create pages after selected page; 2 (default) to create pages at the end of the document</p></dd>
+
+<dt><a name="-newPage"><strong>newPage</strong></a>(...)</dt>
+<dd><code>newPage(where [,"masterpage"])</code>
+<p>Creates a new page. If "where" is -1 the new Page is appended to the document, otherwise the new page is inserted before "where". Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is. The optional parameter "masterpage" specifies the name of the master page for the new page.</p>
+<p>May raise IndexError if the page number is out of range</p></dd>
+	
+<dt><a name="-pageCount"><strong>pageCount</strong></a>(...)</dt>
+<dd><code>pageCount() -> integer</code>
+<p>Returns the number of pages in the document.</p>
+<p>There is also a special character for page count, in decimal 23, and in hex 0x17. You might combine this with the special character for current page in a text frame (on a Master Page for example) as follows. Either of these is equivalent:</p></dd>
+<dd><p><b>scribus.setText('Page ' + chr(30) + ' of ' + chr(23), textframe)</b></p>
+<p><b>scribus.setText('Page \x1e of \x17', textframe)</p></b></dd>
+
+<dt><a name="-redrawAll"><strong>redrawAll</strong></a>(...)</dt>
+<dd><code>redrawAll()</code>
+<p>Redraws all pages.</p></dd>
+
+<dt><a name="-savePageAsEPS"><strong>savePageAsEPS</strong></a>(...)</dt>
+<dd><code>savePageAsEPS("name")</code>
+<p>Saves the current page as an EPS to the file "name".</p>
+<p>May raise ScribusError if the save failed.</p></dd>
+
+<dt><a name="-setHGuides"><strong>setHGuides</strong></a>(...)</dt>
+<dd><code>setHGuides(list)</code>
+<p>Sets horizontal guides. Input parameter must be a list of guide positions measured in the current document units - see UNIT_<type> constants.</p>
+<p>Example:</p>
+<p><b>setHGuides(getHGuides() + [200.0, 210.0])</b> # this will add new guides while saving existing guides</p>
+<p><b>setHGuides([90,250])</b> # this will replace current guides entirely</p></dd>
+
+<dt><a name="-setRedraw"><strong>setRedraw</strong></a>(...)</dt>
+<dd><code>setRedraw(bool)</code>
+<p>Disables page redraw when bool = False, otherwise redrawing is enabled. This change will persist even after the script exits, so make sure to call <a href="#-setRedraw">setRedraw</a>(True) in a finally: clause at the top level of your script.</p></dd>
+
+<dt><a name="-setVGuides"><strong>setVGuides</strong></a>(...)</dt>
+<dd><code>setVGuides()</code>
+<p>The usage is analagous to that of <a href="#-setHGuides">setHGuides</a> for either adding to existing guides or replacing them.</p></dd>
+
+</dl>
+</body>
+</html>

Modified: trunk/Scribus/doc/ru/scripterapi-page.html
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23382&path=/trunk/Scribus/doc/ru/scripterapi-page.html
==============================================================================
--- trunk/Scribus/doc/ru/scripterapi-page.html	(original)
+++ trunk/Scribus/doc/ru/scripterapi-page.html	Wed Nov 27 00:02:13 2019
@@ -1,130 +1,133 @@
-<html dir="ltr">
-<head>
-	<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
-	<title>Page related Commands</title>
-</head>
-<style>
- at import "manual.css";
-</style>
-<body>
-<h2>Page related Commands</h2>
-
-<dl>
-
-<dt><a name="-applyMasterPage"><strong>applyMasterPage</strong>(...)</a></dt>
-<dd><code>applyMasterPage(Master Page name, page nr)</code>
-<p>Applies the named master page to the indicated page. Some examples of usage are on the wiki..</p></dd>
-
-<dt><a name="-closeMasterPage"><strong>closeMasterPage</strong>(...)</a></dt>
-<dd><code>closeMasterPage()</code>
-<p>Closes the currently active master page, if any, and returns editing to normal. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
-
-<dt><a name="-createMasterPage"><strong>createMasterPage</strong>(...)</a></dt>
-<dd><code>createMasterPage(pageName)</code>
-<p>Creates a new master page named pageName. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
-
-<dt><a name="-currentPage"><strong>currentPage</strong></a>(...)</dt>
-<dd><code>currentPage() -> integer</code>
-<p>Returns the number of the current working page. Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is.</p>
-<p>If you want to enter into a text frame the special character for the current page number, it is decimal 30 or hex 0x1e. For example, either of the following would be equivalent:</p></dd>
-<dd><p><b>scribus.setText('Page ' + chr(30), textframe)</b></p></dd>
-<dd><p><b>scribus.setText('Page \x1e', textframe)</b></p></dd>
-<dd><p>See also <strong>pageCount()</strong></dd>
-
-<dt><a name="-deleteMasterPage"><strong>deleteMasterPage</strong>(...)</a></dt>
-<dd><code>deleteMasterPage(pageName)</code>
-<p>Delete the named master page.</p></dd>
-
-<dt><a name="-deletePage"><strong>deletePage</strong></a>(...)</dt>
-<dd><code>deletePage(nr)</code>
-<p>Deletes the given page. Does nothing if the document contains only one page. Page numbers are counted from 1 upwards, no matter what the displayed first page number is.</p>
-<p>May raise IndexError if the page number is out of range</p></dd>
-
-<dt><a name="-editMasterPage"><strong>editMasterPage</strong>(...)</a></dt>
-<dd><code>editMasterPage(pageName)</code>
-<p>Enables master page editing and opens the named master page for editing. Finish editing with <a href="#-closeMasterPage">closeMasterPage()</a>.</p></dd>
-
-<dt><a name="-getAllObjects"><strong>getAllObjects</strong></a>(...)</dt>
-<dd><code>getAllObjects() -> list</code>
-<p>Returns a list containing the names of all objects on the current page.</p></dd>
-
-<dt><a name="-getHGuides"><strong>getHGuides</strong></a>(...)</dt>
-<dd><code>getHGuides() -> list</code>
-<p>Returns a list containing positions of the horizontal guides. Values are in the document's current units - see UNIT_<type> constants.</p></dd>
-
-<dt><a name="-getPageType"><strong>getPageType</strong>(...)</a></dt>
-<dd><code>getPageType() -> integer</code>
-<p>Returns the type of the Page, 0 means left Page, 1 is a middle Page and 2 is a right Page</p></dd>
-
-<dt><a name="-getVGuides"><strong>getVGuides</strong></a>(...)</dt>
-<dd><code>getVGuides()</code>
-<p>See <a href="#-getHGuides">getHGuides</a>.</p></dd>
-
-<dt><a name="-getPageItems"><strong>getPageItems</strong></a>(...)</dt>
-<dd><code>getPageItems() -> list</code>
-<p>Returns a list of tuples with items on the current page. The tuple is: (name, objectType, order) E.g. [('Text1', 4, 0), ('Image1', 2, 1)] means that object named 'Text1' is a text frame (type 4) and is the first at the page...</p></dd>
-
-<dt><a name="-getPageMargins"><strong>getPageMargins</strong></a>(...)</dt>
-<dd><code>getPageMargins()</code>
-<p>Returns the document page margins as a (top, left, right, bottom) tuple in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
-
-<dt><a name="-getPageNMargins"><strong>getPageNMargins</strong></a>(...)</dt>
-<dd><code>getPageNMargins(nr)</code>
-<p>Returns a tuple with a particular page's margins measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
-
-<dt><a name="-getPageSize"><strong>getPageSize</strong></a>(...)</dt>
-<dd><code>getPageSize() -> tuple</code>
-<p>Returns a tuple with document page dimensions measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
-
-<dt><a name="-getPageNSize"><strong>getPageNSize</strong></a>(...)</dt>
-<dd><code>getPageNSize(nr) -> tuple</code>
-<p>Returns a tuple with a particular page's size measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
-
-<dt><a name="-gotoPage"><strong>gotoPage</strong></a>(...)</dt>
-<dd><code>gotoPage(nr)</code>
-<p>Moves to the page "nr" (that is, makes the current page "nr"). Note that gotoPage doesn't (currently) change the page the user's view is displaying, it just sets the page that script commands will operates on.</p>
-<p>May raise IndexError if the page number is out of range.</p></dd>
-
-<dt><a name="-importPage"><strong>importPage</strong>(...)</a></dt>
-<dd><code></code>
-<p>importPage("fromDoc", (pageList), [create, importwhere, importwherePage]) Imports a set of pages (given as a tuple) from an existing document (the file name must be given). This functions maps the "Page->Import" dropdown menu function. fromDoc: string; the filename of the document to import pages from pageList: tuple with page numbers of pages to import create: number; 0 to replace existing pages, 1 (default) to insert new pages importWhere: number; the page number (of the current document) at which import the pages importWherePage: number; used if create==1; 0 to create pages before selected page; 1 to create pages after selected page; 2 (default) to create pages at the end of the document</p></dd>
-
-<dt><a name="-newPage"><strong>newPage</strong></a>(...)</dt>
-<dd><code>newPage(where [,"masterpage"])</code>
-<p>Creates a new page. If "where" is -1 the new Page is appended to the document, otherwise the new page is inserted before "where". Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is. The optional parameter "masterpage" specifies the name of the master page for the new page.</p>
-<p>May raise IndexError if the page number is out of range</p></dd>
-	
-<dt><a name="-pageCount"><strong>pageCount</strong></a>(...)</dt>
-<dd><code>pageCount() -> integer</code>
-<p>Returns the number of pages in the document.</p>
-<p>There is also a special character for page count, in decimal 23, and in hex 0x17. You might combine this with the special character for current page in a text frame (on a Master Page for example) as follows. Either of these is equivalent:</p></dd>
-<dd><p><b>scribus.setText('Page ' + chr(30) + ' of ' + chr(23), textframe)</b></p>
-<p><b>scribus.setText('Page \x1e of \x17', textframe)<p></b></dd>
-
-<dt><a name="-redrawAll"><strong>redrawAll</strong></a>(...)</dt>
-<dd><code>redrawAll()</code>
-<p>Redraws all pages.</p></dd>
-
-<dt><a name="-savePageAsEPS"><strong>savePageAsEPS</strong></a>(...)</dt>
-<dd><code>savePageAsEPS("name")</code>
-<p>Saves the current page as an EPS to the file "name".</p>
-<p>May raise ScribusError if the save failed.</p></dd>
-
-<dt><a name="-setHGuides"><strong>setHGuides</strong></a>(...)</dt>
-<dd><code>setHGuides(list)</code>
-<p>Sets horizontal guides. Input parameter must be a list of guide positions measured in the current document units - see UNIT_<type> constants.</p>
-<p>Например:</p>
-<p><b>setHGuides(getHGuides() + [200.0, 210.0])</b> # this will add new guides while saving existing guides</p>
-<p><b>setHGuides([90,250])</b> # this will replace current guides entirely</p></dd>
-
-<dt><a name="-setRedraw"><strong>setRedraw</strong></a>(...)</dt>
-<dd><code>setRedraw(bool)</code>
-<p>Disables page redraw when bool = False, otherwise redrawing is enabled. This change will persist even after the script exits, so make sure to call <a href="#-setRedraw">setRedraw</a>(True) in a finally: clause at the top level of your script.</p></dd>
-
-<dt><a name="-setVGuides"><strong>setVGuides</strong></a>(...)</dt>
-<dd><code>setVGuides()</code>
-<p>The usage is analagous to that of <a href="#-setHGuides">setHGuides</a> for either adding to existing guides or replacing them.</p></dd>
-
-</dl>
-</body>
-</html>
+<html>
+<head>
+	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+	<title>Page related Commands</title>
+</head>
+<style>
+ at import "manual.css";
+</style>
+<body>
+<h2>Page related Commands</h2>
+
+<dl>
+
+<dt><a name="-applyMasterPage"><strong>applyMasterPage</strong>(...)</a></dt>
+<dd><code>applyMasterPage(masterPageName, pageNr)</code>
+<p>Applies the named master page to the indicated page. Some examples of usage are on the wiki.</a>.</p></dd>
+
+<dt><a name="-closeMasterPage"><strong>closeMasterPage</strong>(...)</a></dt>
+<dd><code>closeMasterPage()</code>
+<p>Closes the currently active master page, if any, and returns editing
+to normal. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
+
+<dt><a name="-createMasterPage"><strong>createMasterPage</strong>(...)</a></dt>
+<dd><code>createMasterPage(pageName)</code>
+<p>Creates a new master page named pageName. Begin editing with <a href="#-editMasterPage">editMasterPage()</a>.</p></dd>
+
+<dt><a name="-currentPage"><strong>currentPage</strong></a>(...)</dt>
+<dd><code>currentPage() -> integer</code>
+<p>Returns the number of the current working page. Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is.</p>
+<p>If you want to enter into a text frame the special character for the current page number, it is decimal 30 or hex 0x1e. For example, either of the following would be equivalent:</p></dd>
+<dd><p><b>scribus.setText('Page ' + chr(30), textframe)</b></p></dd>
+<dd><p><b>scribus.setText('Page \x1e', textframe)</b></p></dd>
+<dd><p>See also <strong>pageCount()</strong></dd>
+
+<dt><a name="-deleteMasterPage"><strong>deleteMasterPage</strong>(...)</a></dt>
+<dd><code>deleteMasterPage(pageName)</code>
+<p>Delete the named master page.</p></dd>
+
+<dt><a name="-deletePage"><strong>deletePage</strong></a>(...)</dt>
+<dd><code>deletePage(nr)</code>
+<p>Deletes the given page. Does nothing if the document contains only one page. Page numbers are counted from 1 upwards, no matter what the displayed first page number is.</p>
+<p>May raise IndexError if the page number is out of range</p></dd>
+
+<dt><a name="-editMasterPage"><strong>editMasterPage</strong>(...)</a></dt>
+<dd><code>editMasterPage(pageName)</code>
+<p>Enables master page editing and opens the named master page
+for editing. Finish editing with <a href="#-closeMasterPage">closeMasterPage()</a>.</p></dd>
+
+<dt><a name="-getAllObjects"><strong>getAllObjects</strong></a>(...)</dt>
+<dd><code>getAllObjects() -> list</code>
+<p>Returns a list containing the names of all objects on the current page.</p></dd>
+
+<dt><a name="-getHGuides"><strong>getHGuides</strong></a>(...)</dt>
+<dd><code>getHGuides() -> list</code>
+<p>Returns a list containing positions of the horizontal guides. Values are in the
+document's current units - see UNIT_<type> constants.</p></dd>
+
+<dt><a name="-getPageType"><strong>getPageType</strong>(...)</a></dt>
+<dd><code>getPageType() -> integer</code>
+<p>Returns the type of the Page, 0 means left Page, 1 is a middle Page and 2 is a right Page</p></dd>
+
+<dt><a name="-getVGuides"><strong>getVGuides</strong></a>(...)</dt>
+<dd><code>getVGuides()</code>
+<p>See <a href="#-getHGuides">getHGuides</a>.</p></dd>
+
+<dt><a name="-getPageItems"><strong>getPageItems</strong></a>(...)</dt>
+<dd><code>getPageItems() -> list</code>
+<p>Returns a list of tuples with items on the current page. The tuple is: (name, objectType, order) E.g. [('Text1', 4, 0), ('Image1', 2, 1)] means that object named 'Text1' is a text frame (type 4) and is the first at the page...</p></dd>
+
+<dt><a name="-getPageMargins"><strong>getPageMargins</strong></a>(...)</dt>
+<dd><code>getPageMargins()</code>
+<p>Returns the document page margins as a (top, left, right, bottom) tuple in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
+
+<dt><a name="-getPageNMargins"><strong>getPageNMargins</strong></a>(...)</dt>
+<dd><code>getPageNMargins(nr)</code>
+<p>Returns a tuple with a particular page's margins measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageSize">getPageSize</a>().</p></dd>
+
+<dt><a name="-getPageSize"><strong>getPageSize</strong></a>(...)</dt>
+<dd><code>getPageSize() -> tuple</code>
+<p>Returns a tuple with document page dimensions measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
+
+<dt><a name="-getPageNSize"><strong>getPageNSize</strong></a>(...)</dt>
+<dd><code>getPageNSize(nr) -> tuple</code>
+<p>Returns a tuple with a particular page's size measured in the document's current units. See UNIT_<type> constants and <a href="#-getPageMargins">getPageMargins</a>()</p></dd>
+
+<dt><a name="-gotoPage"><strong>gotoPage</strong></a>(...)</dt>
+<dd><code>gotoPage(nr)</code>
+<p>Moves to the page "nr" (that is, makes the current page "nr"). Note that gotoPage doesn't (currently) change the page the user's view is displaying, it just sets the page that script commands will operates on.</p>
+<p>May raise IndexError if the page number is out of range.</p></dd>
+
+<dt><a name="-importPage"><strong>importPage</strong>(...)</a></dt>
+<dd><code></code>
+<p>importPage("fromDoc", (pageList), [create, importwhere, importwherePage]) Imports a set of pages (given as a tuple) from an existing document (the file name must be given). This functions maps the "Page->Import" dropdown menu function. fromDoc: string; the filename of the document to import pages from pageList: tuple with page numbers of pages to import create: number; 0 to replace existing pages, 1 (default) to insert new pages importWhere: number; the page number (of the current document) at which import the pages importWherePage: number; used if create==1; 0 to create pages before selected page; 1 to create pages after selected page; 2 (default) to create pages at the end of the document</p></dd>
+
+<dt><a name="-newPage"><strong>newPage</strong></a>(...)</dt>
+<dd><code>newPage(where [,"masterpage"])</code>
+<p>Creates a new page. If "where" is -1 the new Page is appended to the document, otherwise the new page is inserted before "where". Page numbers are counted from 1 upwards, no matter what the displayed first page number of your document is. The optional parameter "masterpage" specifies the name of the master page for the new page.</p>
+<p>May raise IndexError if the page number is out of range</p></dd>
+	
+<dt><a name="-pageCount"><strong>pageCount</strong></a>(...)</dt>
+<dd><code>pageCount() -> integer</code>
+<p>Returns the number of pages in the document.</p>
+<p>There is also a special character for page count, in decimal 23, and in hex 0x17. You might combine this with the special character for current page in a text frame (on a Master Page for example) as follows. Either of these is equivalent:</p></dd>
+<dd><p><b>scribus.setText('Page ' + chr(30) + ' of ' + chr(23), textframe)</b></p>
+<p><b>scribus.setText('Page \x1e of \x17', textframe)</p></b></dd>
+
+<dt><a name="-redrawAll"><strong>redrawAll</strong></a>(...)</dt>
+<dd><code>redrawAll()</code>
+<p>Redraws all pages.</p></dd>
+
+<dt><a name="-savePageAsEPS"><strong>savePageAsEPS</strong></a>(...)</dt>
+<dd><code>savePageAsEPS("name")</code>
+<p>Saves the current page as an EPS to the file "name".</p>
+<p>May raise ScribusError if the save failed.</p></dd>
+
+<dt><a name="-setHGuides"><strong>setHGuides</strong></a>(...)</dt>
+<dd><code>setHGuides(list)</code>
+<p>Sets horizontal guides. Input parameter must be a list of guide positions measured in the current document units - see UNIT_<type> constants.</p>
+<p>Example:</p>
+<p><b>setHGuides(getHGuides() + [200.0, 210.0])</b> # this will add new guides while saving existing guides</p>
+<p><b>setHGuides([90,250])</b> # this will replace current guides entirely</p></dd>
+
+<dt><a name="-setRedraw"><strong>setRedraw</strong></a>(...)</dt>
+<dd><code>setRedraw(bool)</code>
+<p>Disables page redraw when bool = False, otherwise redrawing is enabled. This change will persist even after the script exits, so make sure to call <a href="#-setRedraw">setRedraw</a>(True) in a finally: clause at the top level of your script.</p></dd>
+
+<dt><a name="-setVGuides"><strong>setVGuides</strong></a>(...)</dt>
+<dd><code>setVGuides()</code>
+<p>The usage is analagous to that of <a href="#-setHGuides">setHGuides</a> for either adding to existing guides or replacing them.</p></dd>
+
+</dl>
+</body>
+</html>




More information about the scribus-commit mailing list