[Yrogirg] configurable latex formulas font size. Fixes #3986
This commit is contained in:
parent
d927d260c2
commit
8f9c097343
|
@ -250,6 +250,7 @@ class Config:
|
|||
'max_conversation_lines': [opt_int, 500, _('Maximum number of lines that are printed in conversations. Oldest lines are cleared.')],
|
||||
'attach_notifications_to_systray': [opt_bool, False, _('If True, notification windows from notification-daemon will be attached to systray icon.')],
|
||||
'check_idle_every_foo_seconds': [opt_int, 2, _('Choose interval between 2 checks of idleness.')],
|
||||
'latex_png_dpi': [opt_str, '108',_('Change the value to change the size of latex formulas displayed. The higher is larger.') ],
|
||||
}
|
||||
|
||||
__options_per_key = {
|
||||
|
|
|
@ -854,15 +854,8 @@ class ConversationTextview:
|
|||
exitcode = p.wait()
|
||||
|
||||
if exitcode == 0:
|
||||
convert_version = helpers.get_output_of_command(
|
||||
'convert -version')[0].split()[2]
|
||||
convert_version = [int(n) for n in convert_version.split('.')]
|
||||
if convert_version > [6, 3, 4]:
|
||||
# -alpha option was added in 6.3.5 release
|
||||
alpha = ['-alpha', 'off']
|
||||
else:
|
||||
alpha = []
|
||||
p = Popen(['convert'] + alpha + [tmpfile + '.ps', tmpfile + '.png'],
|
||||
latex_png_dpi = gajim.config.get('latex_png_dpi')
|
||||
p = Popen(['convert', '-background', 'white', '-flatten', '-density', latex_png_dpi, tmpfile + '.ps', tmpfile + '.png'],
|
||||
cwd=gettempdir())
|
||||
exitcode = p.wait()
|
||||
|
||||
|
|
Loading…
Reference in New Issue