SOF UNO constants too

This commit is contained in:
Jonathan Corwin 2011-06-23 23:53:24 +01:00
parent e1dc332be4
commit d58682ad6b
1 changed files with 8 additions and 5 deletions

View File

@ -41,20 +41,23 @@ from oooimport import OooImport
log = logging.getLogger(__name__)
if os.name == u'nt':
BOLD = 150.0
ITALIC = 2
from oooimport import PAGE_BEFORE, PAGE_AFTER, PAGE_BOTH
RuntimeException = Exception
else:
try:
from com.sun.star.awt.FontWeight import BOLD
from com.sun.star.awt.FontSlant import ITALIC
from com.sun.star.style.BreakType import PAGE_BEFORE, PAGE_AFTER, \
PAGE_BOTH
from com.sun.star.uno import RuntimeException
except ImportError:
pass
try:
from com.sun.star.awt.FontWeight import BOLD
except ImportError:
BOLD = 150.0
try:
from com.sun.star.awt.FontSlant import ITALIC
except ImportError:
ITALIC = 2
class SofImport(OooImport):
"""