support for the Iwona fonts

- the support for Iwona is exactly the same as for the Kurier fonts
- fileformat change
This commit is contained in:
Uwe Stöhr 2013-03-19 00:57:37 +01:00
parent 9548274f39
commit f08f5821ec
6 changed files with 76 additions and 4 deletions

View File

@ -11,6 +11,11 @@ adjustments are made to tex2lyx and bugs are fixed in lyx2lyx.
-----------------------
2013-08-19 Uwe Stöhr <uwestoehr@web.de>
* Format incremented to 467: support for iwona fonts
new supported sansserif fonts "iwona", "iwonal", "iwonac"
and "iwonalc" and the math font "iwona-math"
2013-03-17 Jürgen Spitzmüller <spitz@lyx.org>
* Format incremented to 466: Powerdot updates.
- Support for item arguments ([...], <...>)

View File

@ -413,6 +413,7 @@
\TestPackage{fourier}
\TestPackage{garamondx}
\TestFont[zgmr8r]{garamondx-fonts}
\TestPackage{iwona}
\TestPackage{kurier}
\TestPackage{lh-lcy}
\TestPackage{libertine}

View File

@ -460,6 +460,34 @@ Font helvet
Requires psnfss
EndFont
Font iwona
GuiName "Iwona"
Family sf
Requires iwona
SwitchDefault 1
EndFont
Font iwonal
GuiName "Iwona (Light)"
Family sf
Requires iwona
SwitchDefault 1
EndFont
Font iwonac
GuiName "Iwona (Condensed)"
Family sf
Requires iwona
SwitchDefault 1
EndFont
Font iwonalc
GuiName "Iwona (Light Condensed)"
Family sf
Requires iwona
SwitchDefault 1
EndFont
Font kurier
GuiName "Kurier"
Family sf
@ -600,6 +628,19 @@ Font garamondx-ntxm
Provides amssymb,amsfonts
EndFont
Font iwona-math
GuiName "Iwona (Math)"
Family math
Requires iwona
Preamble
% store roman font
\let\origrmdefault\rmdefault
\usepackage[math]{iwona}
% reset stored roman font
\renewcommand{\rmdefault}{\origrmdefault}
EndPreamble
EndFont
Font kurier-math
GuiName "Kurier (Math)"
Family math

View File

@ -3630,6 +3630,28 @@ def revert_kurier_fonts(document):
add_to_preamble(document, "\\renewcommand{\\sfdefault}{%s}" % sf)
document.header[k] = "\\font_sans default"
def revert_iwona_fonts(document):
" Revert iwona font definition to LaTeX "
i = find_token(document.header, "\\font_math", 0)
if i != -1:
if find_token(document.header, "\\use_non_tex_fonts false", 0) != -1:
val = get_value(document.header, "\\font_math", i)
if val == "iwona-math":
add_to_preamble(document, "\\let\\Myrmdefault\\rmdefault\n" \
"\\usepackage[math]{iwona}\n" \
"\\renewcommand{\\rmdefault}{\\Myrmdefault}")
document.header[i] = "\\font_math auto"
if find_token(document.header, "\\use_non_tex_fonts false", 0) != -1:
iwona_fonts = ["iwona", "iwonac", "iwonal", "iwonalc"]
k = find_token(document.header, "\\font_sans iwona", 0)
if k != -1:
sf = get_value(document.header, "\\font_sans", k)
if sf in iwona_fonts:
add_to_preamble(document, "\\renewcommand{\\sfdefault}{%s}" % sf)
document.header[k] = "\\font_sans default"
def revert_new_libertines(document):
" Revert new libertine font definition to LaTeX "
@ -4087,10 +4109,12 @@ convert = [
[463, [convert_encodings]],
[464, [convert_use_cancel]],
[465, [convert_lyxframes, remove_endframes]],
[466, []]
[466, []],
[467, []]
]
revert = [
[466, [revert_iwona_fonts]],
[465, [revert_powerdot_flexes, revert_powerdot_pause, revert_powerdot_itemargs, revert_powerdot_columns]],
[464, []],
[463, [revert_use_cancel]],

View File

@ -129,7 +129,8 @@ const char * const known_roman_fonts[] = { "ae", "beraserif", "bookman",
"tgbonum", "tgchorus", "tgpagella", "tgschola", "tgtermes", "utopia", 0};
const char * const known_sans_fonts[] = { "avant", "berasans", "biolinum-type1",
"cmbr", "cmss", "helvet", "kurier", "kurierl", "lmss", "tgadventor", "tgheros", 0};
"cmbr", "cmss", "helvet", "iwona", "iwonal", "kurier", "kurierl", "lmss",
"tgadventor", "tgheros", 0};
const char * const known_kurier_fonts[] = { "kurier", "kurierl",
"kurier-condensed", "kurier-light-condensed", 0};

View File

@ -30,8 +30,8 @@ extern char const * const lyx_version_info;
// Do not remove the comment below, so we get merge conflict in
// independent branches. Instead add your own.
#define LYX_FORMAT_LYX 466 // spitz: powerdot updates
#define LYX_FORMAT_TEX2LYX 466 // spitz: powerdot updates
#define LYX_FORMAT_LYX 467 // uwestoehr: iwona font support
#define LYX_FORMAT_TEX2LYX 467 // uwestoehr: iwona font support
#if LYX_FORMAT_TEX2LYX != LYX_FORMAT_LYX
#ifndef _MSC_VER