diff options
author | Rafael Lima <rafael.palma.lima@gmail.com> | 2021-06-21 19:12:17 +0200 |
---|---|---|
committer | Olivier Hallot <olivier.hallot@libreoffice.org> | 2021-06-23 21:29:31 +0200 |
commit | 0ce7571dc9f2262e6ef9f50f895b840813e9b30a (patch) | |
tree | 4400947708b97c4e5d397113092f7663d3133c84 | |
parent | 01cddc5a7b30380e3fe0d7dd832b250e85bb5f7c (diff) |
Add note about Python support availability on some SF services
This patch is being cherry-picked for LO 7.2 because some SF services have Python support but the help pages could not be updated in time.
Hence, this patch adds a note to these help pages to let users know that these SF services also support Python.
Change-Id: I226b0b92fcc2b380fa6687cba87276b485009151
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/117567
Tested-by: Jenkins
Tested-by: Jean-Pierre Ledure <jp@ledure.be>
Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
(cherry picked from commit 3c0fb9a710915c30adf5287a734a185696fa0b76)
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/117635
-rw-r--r-- | source/text/sbasic/shared/00000003.xhp | 4 | ||||
-rw-r--r-- | source/text/sbasic/shared/03/sf_database.xhp | 1 | ||||
-rw-r--r-- | source/text/sbasic/shared/03/sf_filesystem.xhp | 1 | ||||
-rw-r--r-- | source/text/sbasic/shared/03/sf_l10n.xhp | 2 | ||||
-rw-r--r-- | source/text/sbasic/shared/03/sf_platform.xhp | 1 | ||||
-rw-r--r-- | source/text/sbasic/shared/03/sf_session.xhp | 2 | ||||
-rw-r--r-- | source/text/sbasic/shared/03/sf_textstream.xhp | 1 | ||||
-rw-r--r-- | source/text/sbasic/shared/03/sf_timer.xhp | 2 |
8 files changed, 12 insertions, 2 deletions
diff --git a/source/text/sbasic/shared/00000003.xhp b/source/text/sbasic/shared/00000003.xhp index 9f24e8eb68..5c2b7fb2be 100644 --- a/source/text/sbasic/shared/00000003.xhp +++ b/source/text/sbasic/shared/00000003.xhp @@ -232,6 +232,10 @@ <warning id="par_id81621427048241">This method requires the installation of the <link href="https://extensions.libreoffice.org/en/extensions/show/apso-alternative-script-organizer-for-python" name="APSO Link">APSO (Alternative Script Organizer for Python)</link> extension. If it is not installed, an error will occur.</warning> </section> +<section id="Python_Support"> +<note id="par_id21624295605301">This service is fully supported in both Basic and Python languages. All examples are expressed using the Basic programming language and can be easily converted to Python.</note> +</section> + <paragraph role="paragraph" id="par_id161599082457466"><variable id="stringfunctions"><link href="text/sbasic/shared/03120300.xhp" name="string functions">String functions</link></variable></paragraph> diff --git a/source/text/sbasic/shared/03/sf_database.xhp b/source/text/sbasic/shared/03/sf_database.xhp index 3b67abbe87..bbc936356f 100644 --- a/source/text/sbasic/shared/03/sf_database.xhp +++ b/source/text/sbasic/shared/03/sf_database.xhp @@ -59,6 +59,7 @@ <paragraph role="paragraph" id="par_id491615147048748">Conversely, if a <literal>RegistrationName</literal> is specified, the <literal>FileName</literal> parameter should not be defined.</paragraph> <paragraph role="paragraph" id="par_id841615147168279"><emph>ReadOnly</emph>: Determines if the database will be opened as readonly (Default = <literal>True</literal>).</paragraph> <paragraph role="paragraph" id="par_id291615147236001"><emph>User, Password</emph>: Additional connection parameters to the database server.</paragraph> + <embed href="text/sbasic/shared/00000003.xhp#Python_Support"/> <h2 id="hd_id771615147491563">Accessing Databases with the UI Service</h2> <paragraph role="paragraph" id="par_id901599408410712" xml-lang="en-US">It is also possible to access the database associated with a Base document using the <link href="text/sbasic/shared/03/sf_ui.xhp" name="UI Service"><literal>ScriptForge.UI</literal></link> service, as shown in the example below:</paragraph> diff --git a/source/text/sbasic/shared/03/sf_filesystem.xhp b/source/text/sbasic/shared/03/sf_filesystem.xhp index e598a32382..18b36a4b99 100644 --- a/source/text/sbasic/shared/03/sf_filesystem.xhp +++ b/source/text/sbasic/shared/03/sf_filesystem.xhp @@ -121,6 +121,7 @@ <paragraph role="bascode" localize="false" id="bas_id201582885621287">FSO = CreateScriptService("FileSystem")</paragraph> <paragraph role="bascode" localize="false" id="bas_id901612990364784">FSO.BuildPath(...)</paragraph> </bascode> + <embed href="text/sbasic/shared/00000003.xhp#Python_Support"/> <bookmark xml-lang="en-US" branch="index" id="bm_id901612991354326" localize="false"> <bookmark_value>FileSystem service;FileNaming property</bookmark_value> diff --git a/source/text/sbasic/shared/03/sf_l10n.xhp b/source/text/sbasic/shared/03/sf_l10n.xhp index 2cf76682a4..2a964fe003 100644 --- a/source/text/sbasic/shared/03/sf_l10n.xhp +++ b/source/text/sbasic/shared/03/sf_l10n.xhp @@ -24,7 +24,6 @@ <section id="abstract"> <h1 id="hd_id521585843652750" xml-lang="en-US"><variable id="L10NService"><link href="text/sbasic/shared/03/sf_l10n.xhp" name="L10N service"><literal>ScriptForge</literal>.<literal>L10N</literal> service</link></variable></h1> - <paragraph role="paragraph" xml-lang="en-US" id="par_id411585843652556">This service provides a number of methods related to the translation of strings with minimal impact on the program's source code. The methods provided by the <literal>L10N</literal> service can be used mainly to:</paragraph> <list type="unordered"> <listitem> @@ -63,6 +62,7 @@ <paragraph role="paragraph" id="par_id331585843652877" xml-lang="en-US"><emph>FolderName</emph>: The folder containing the PO files. It must be expressed in the <literal>FileSystem.FileNaming</literal> notation.</paragraph> <paragraph role="paragraph" id="par_id581585843652789" xml-lang="en-US"><emph>Locale</emph>: A string in the form "la-CO" (language-COUNTRY) or in the form "la" (language) only.</paragraph> <note id="par_id301614358956087">Several instances of the <literal>L10N</literal> service may coexist. However, each instance must use a separate directory for its PO files.</note> + <embed href="text/sbasic/shared/00000003.xhp#Python_Support"/> <h3 id="hd_id481585843652711" localize="false"><embedvar href="text/sbasic/shared/00000003.xhp#functexample"/></h3> <paragraph role="paragraph" id="par_id891614358528334">The following example instantiates the <literal>L10N</literal> service without any optional arguments. This will only enable the <literal>AddText</literal> and <literal>ExportToPOTFile</literal> methods.</paragraph> <bascode> diff --git a/source/text/sbasic/shared/03/sf_platform.xhp b/source/text/sbasic/shared/03/sf_platform.xhp index d66f41827e..ef534cc867 100644 --- a/source/text/sbasic/shared/03/sf_platform.xhp +++ b/source/text/sbasic/shared/03/sf_platform.xhp @@ -47,6 +47,7 @@ <paragraph role="bascode" localize="false" id="bas_id721600788076288">platform = CreateScriptService("Platform")</paragraph> <paragraph role="bascode" localize="false" id="bas_id791600788431935">MsgBox platform.Architecture</paragraph> </bascode> + <embed href="text/sbasic/shared/00000003.xhp#Python_Support"/> <bookmark xml-lang="en-US" branch="index" localize="false" id="bm_id111614901524769"> <bookmark_value>Platform service;Architecture</bookmark_value> <bookmark_value>Platform service;ComputerName</bookmark_value> diff --git a/source/text/sbasic/shared/03/sf_session.xhp b/source/text/sbasic/shared/03/sf_session.xhp index 26d533188b..5713bf4976 100644 --- a/source/text/sbasic/shared/03/sf_session.xhp +++ b/source/text/sbasic/shared/03/sf_session.xhp @@ -46,7 +46,7 @@ <paragraph role="bascode" localize="false" id="bas_id961582814720760">Dim session As Variant</paragraph> <paragraph role="bascode" localize="false" id="bas_id651582814720203">session = CreateScriptService("Session")</paragraph> </bascode> - + <embed href="text/sbasic/shared/00000003.xhp#Python_Support"/> <h2 id="hd_id291582814720762" xml-lang="en-US">Constants</h2> <paragraph role="paragraph" id="par_id82158281472034" xml-lang="en-US">Below is a list of constants available to ease the designation of the library containing a Basic or Python script to invoke. <br />Use them as <literal>session.CONSTANT</literal>.</paragraph> diff --git a/source/text/sbasic/shared/03/sf_textstream.xhp b/source/text/sbasic/shared/03/sf_textstream.xhp index 1659d32a54..61210f46c0 100644 --- a/source/text/sbasic/shared/03/sf_textstream.xhp +++ b/source/text/sbasic/shared/03/sf_textstream.xhp @@ -40,6 +40,7 @@ <paragraph role="bascode" localize="false" id="bas_id11585330787585">FSO = CreateScriptService("FileSystem")</paragraph> <paragraph role="bascode" localize="false" id="bas_id891585330787374">Set myFile = FSO.OpenTextFile("C:\Temp\ThisFile.txt", FSO.ForReading)</paragraph> </bascode> + <embed href="text/sbasic/shared/00000003.xhp#Python_Support"/> <paragraph role="paragraph" id="par_id371585330787197" xml-lang="en-US">The file must be closed with the <literal>CloseFile</literal> method after all read or write operations have been executed:</paragraph> <bascode> <paragraph role="bascode" localize="false" id="bas_id91613599192241">myFile.CloseFile()</paragraph> diff --git a/source/text/sbasic/shared/03/sf_timer.xhp b/source/text/sbasic/shared/03/sf_timer.xhp index 809d473cc6..ae2416cdd5 100644 --- a/source/text/sbasic/shared/03/sf_timer.xhp +++ b/source/text/sbasic/shared/03/sf_timer.xhp @@ -59,6 +59,8 @@ <bascode> <paragraph role="bascode" localize="false" id="bas_id61582733781413">Set myTimer = myTimer.Dispose()</paragraph> </bascode> + <embed href="text/sbasic/shared/00000003.xhp#Python_Support"/> + <h2 id="hd_id521582733781450" xml-lang="en-US">Properties</h2> <table id="tab_id761582733781447"> <tablerow> |