Skip to content
GitLab
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Changes
Page history
Mettre à jour 02.linux examples
authored
Feb 20, 2018
by
LibreOfficiant
Show whitespace changes
Inline
Side-by-side
02.linux-examples.md
View page @
21a17d60
...
...
@@ -15,9 +15,9 @@ g_exportedScripts = macro_1, macro_2 # *Office public macros
```
python
# officehelper module
if
__name__
==
"
__main__
"
:
import
IDE_utils
as
linus
with
linux
.
Runner
()
as
jesse_owens
:
# Start/Stop
XSCRIPTCONTEXT
=
linus
.
XSCRIPTCONTEXT
# Connect/Adapt
import
IDE_utils
as
geany
with
geany
.
Runner
()
as
jesse_owens
:
# Start/Stop
XSCRIPTCONTEXT
=
geany
.
XSCRIPTCONTEXT
# Connect/Adapt
macro_2
()
# Run
```
...
...
@@ -27,7 +27,10 @@ if __name__ == "__main__":
# LibreOffice Named Pipe
if
__name__
==
"
__main__
"
:
import
IDE_utils
as
pycharm
with
pycharm
.
Runner
(
json
=
{
pgm
:
[
*
options
]})
as
carl_lewis
:
# Start/Stop
libre_Office
=
{
"
soffice
"
:
[
'
--accept=pipe,name=LinusTorvalds;urp;
'
,
'
--headless
'
,
'
--nodefault
'
,
'
--nologo
'
]
}
# {pgm: [accept, *options]} service-options key-value pairs
with
pycharm
.
Runner
(
json
=
libre_Off
)
as
carl_lewis
:
# Start/Stop
ctx
=
pycharm
.
connect
(
pipe
=
'
LibreOffice
'
)
XSCRIPTCONTEXT
=
pycharm
.
ScriptContext
(
ctx
)
# Adapt
macro_1
()
# Run
...
...
...
...