50 lines
835 B
Python
50 lines
835 B
Python
#!/usr/bin/env python3
|
|
|
|
import easymacro as app
|
|
|
|
|
|
ID_EXTENSION = ''
|
|
_ = None
|
|
|
|
|
|
def from_selection():
|
|
app.debug('From selection')
|
|
return
|
|
|
|
|
|
def from_dialog():
|
|
app.debug('From dialog')
|
|
return
|
|
|
|
|
|
def validate_app():
|
|
msg1 = _('Not found')
|
|
msg2 = _('Found')
|
|
|
|
result = msg1
|
|
if app.paths.exists_app('pdflatex'):
|
|
result = msg2
|
|
msg = f'pdflatex = {result}\n'
|
|
|
|
result = msg1
|
|
if app.paths.exists_app('pdfcrop'):
|
|
result = msg2
|
|
msg += f'pdfcrop = {result}\n'
|
|
|
|
result = msg1
|
|
if app.paths.exists_app('pdf2svg'):
|
|
result = msg2
|
|
msg += f'pdf2svg = {result}\n\n'
|
|
|
|
msg += _('Not used, if not found some application.')
|
|
|
|
app.msgbox(msg)
|
|
return
|
|
|
|
|
|
def run(args, path_locales):
|
|
global _
|
|
_ = app.install_locales(path_locales)
|
|
globals()[args]()
|
|
return
|