Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
OpenGEODE
Commits
f868ae2c
Commit
f868ae2c
authored
Jan 16, 2017
by
Maxime Perrotin
Browse files
In the PR file indent nicely the Text areas
parent
21bb65d3
Changes
4
Hide whitespace changes
Inline
Side-by-side
README.md
View file @
f868ae2c
...
...
@@ -142,6 +142,9 @@ The background pattern was downloaded from www.subtlepatterns.com
Changelog
=========
1.
5.24 (01/2017)
-
PR file use better indentation for text areas (no line return)
1.
5.23 (12/2016)
-
In simulation mode, bugfix in the declaration of the startup function
-
Code generator prepared for model checking
...
...
opengeode/Pr.py
View file @
f868ae2c
...
...
@@ -291,7 +291,9 @@ def _textsymbol(symbol, **kwargs):
result
.
append
(
cif_coord
(
'TEXT'
,
symbol
))
if
symbol
.
text
.
hyperlink
:
result
.
append
(
hyperlink
(
symbol
))
result
.
append
(
unicode
(
symbol
.
text
))
# Align nicely the text (parser will dedent it)
for
line
in
unicode
(
symbol
.
text
).
split
(
'
\n
'
):
result
.
append
(
line
)
result
.
append
(
u
'/* CIF ENDTEXT */'
)
return
result
...
...
opengeode/ogParser.py
View file @
f868ae2c
...
...
@@ -32,6 +32,7 @@ import math
import
logging
import
traceback
import
binascii
from
textwrap
import
dedent
from
itertools
import
chain
,
permutations
,
combinations
from
collections
import
defaultdict
,
Counter
import
antlr3
...
...
@@ -2614,8 +2615,9 @@ def text_area(root, parent=None, context=None):
warnings
.
extend
(
warn
)
elif
child
.
type
==
lexer
.
ENDTEXT
:
userTextStopIndex
=
child
.
getTokenStartIndex
()
-
1
ta
.
inputString
=
token_stream
(
child
).
toString
(
userTextStartIndex
,
userTextStopIndex
).
strip
()
string
=
token_stream
(
child
).
toString
(
userTextStartIndex
,
userTextStopIndex
)
ta
.
inputString
=
dedent
(
string
).
strip
()
elif
child
.
type
==
lexer
.
HYPERLINK
:
ta
.
hyperlink
=
child
.
getChild
(
0
).
toString
()[
1
:
-
1
]
else
:
...
...
opengeode/opengeode.py
View file @
f868ae2c
...
...
@@ -138,7 +138,7 @@ except ImportError:
__all__
=
[
'opengeode'
,
'SDL_Scene'
,
'SDL_View'
,
'parse'
]
__version__
=
'1.5.2
3
'
__version__
=
'1.5.2
4
'
if
hasattr
(
sys
,
'frozen'
):
# Detect if we are running on Windows (py2exe-generated)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment