From 2a4159410151fa9c99adaf56071a370bcb261ac1 Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Sun, 28 Apr 2013 16:03:16 +0200 Subject: add test for ttc subfont loading --- tests/pln-subfont-1.tex | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 tests/pln-subfont-1.tex (limited to 'tests') diff --git a/tests/pln-subfont-1.tex b/tests/pln-subfont-1.tex new file mode 100644 index 0000000..4877682 --- /dev/null +++ b/tests/pln-subfont-1.tex @@ -0,0 +1,12 @@ +\ifdefined\directlua\input luaotfload.sty\fi + +\directlua{ + inspect(fontloader.info"cambria.ttc") +} + +\font\subfontone="file:cambria.ttc(0)" at 42pt +\font\subfonttwo="file:cambria.ttc(1)" at 42pt + +\subfontone foo bar baz \endgraf +\subfonttwo foo bar baz \endgraf +\bye -- cgit v1.2.3 From 2adc02056a47717a8f9fee7a48e62ab5cf50c9c8 Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Mon, 29 Apr 2013 12:07:37 +0200 Subject: add test file for tfm --- tests/pln-tfm.tex | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 tests/pln-tfm.tex (limited to 'tests') diff --git a/tests/pln-tfm.tex b/tests/pln-tfm.tex new file mode 100644 index 0000000..26fa738 --- /dev/null +++ b/tests/pln-tfm.tex @@ -0,0 +1,8 @@ +\ifdefined\directlua\input luaotfload.sty \fi +%% TFM’s can be loaded with a file: request ... +\font\antykwatorunska="file:rm-anttr" +%% or with an anonymous request, like in þe olde TeX: +\font\antykwatorunskabcap=ec-anttbcap +\antykwatorunska foo bar +\antykwatorunskabcap baz xyzzy +\bye -- cgit v1.2.3 From 1a76cea6357f50d7dae752765173af335ba95beb Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Mon, 29 Apr 2013 13:57:35 +0200 Subject: add handler for XeTeX slashed notation --- tests/pln-subfont-1.tex | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tests') diff --git a/tests/pln-subfont-1.tex b/tests/pln-subfont-1.tex index 4877682..fb8e1e7 100644 --- a/tests/pln-subfont-1.tex +++ b/tests/pln-subfont-1.tex @@ -1,12 +1,12 @@ \ifdefined\directlua\input luaotfload.sty\fi - +%% This requires the Cambria fonts from MS. \directlua{ inspect(fontloader.info"cambria.ttc") } - +%% Here we load both subfonts in the collection +%% with the not-quite documented subfont syntax. \font\subfontone="file:cambria.ttc(0)" at 42pt \font\subfonttwo="file:cambria.ttc(1)" at 42pt - \subfontone foo bar baz \endgraf \subfonttwo foo bar baz \endgraf \bye -- cgit v1.2.3 From 19164c39c9f98d9e51a13d5d698f575879f3dfee Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Mon, 29 Apr 2013 14:48:12 +0200 Subject: add examples for XeTeX notation and lookup caching --- tests/pln-request-4-slashed.tex | 12 ++++++++++++ tests/pln-request-5-cached.tex | 17 +++++++++++++++++ 2 files changed, 29 insertions(+) create mode 100644 tests/pln-request-4-slashed.tex create mode 100644 tests/pln-request-5-cached.tex (limited to 'tests') diff --git a/tests/pln-request-4-slashed.tex b/tests/pln-request-4-slashed.tex new file mode 100644 index 0000000..5e7d99e --- /dev/null +++ b/tests/pln-request-4-slashed.tex @@ -0,0 +1,12 @@ +\ifdefined\directlua\input luaotfload.sty\fi +\font\iwona =iwona at 20pt +\font\iwonabold =iwona/b at 20pt +\font\iwonaitalic =iwona/i at 20pt +\font\iwonabolditalic =iwona/bi at 20pt + +\def\test{foo bar baz \endgraf} +{\iwona \test} +{\iwonabold \test} +{\iwonaitalic \test} +{\iwonabolditalic \test} +\bye diff --git a/tests/pln-request-5-cached.tex b/tests/pln-request-5-cached.tex new file mode 100644 index 0000000..437b20d --- /dev/null +++ b/tests/pln-request-5-cached.tex @@ -0,0 +1,17 @@ +\ifdefined\directlua + \directlua{config = config or { luaotfload = { } } + config.luaotfload.resolver = "cached" } + \input luaotfload.sty +\fi + +\font\iwona =name:iwona at 20pt +\font\iwonabold =name:iwona/b at 20pt +\font\iwonaitalic =name:iwona/i at 20pt +\font\iwonabolditalic =name:iwona/bi at 20pt + +\def\test{foo bar baz \endgraf} +{\iwona \test} +{\iwonabold \test} +{\iwonaitalic \test} +{\iwonabolditalic \test} +\bye -- cgit v1.2.3 From e79f34d859d48be485589f19fc6905afa5872a53 Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Mon, 29 Apr 2013 14:52:53 +0200 Subject: only cache ``name:`` lookups --- tests/pln-request-5-cached.tex | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/pln-request-5-cached.tex b/tests/pln-request-5-cached.tex index 437b20d..8ba4a5e 100644 --- a/tests/pln-request-5-cached.tex +++ b/tests/pln-request-5-cached.tex @@ -1,6 +1,7 @@ \ifdefined\directlua \directlua{config = config or { luaotfload = { } } - config.luaotfload.resolver = "cached" } + config.luaotfload.resolver = "cached" + config.luaotfload.loglevel = 5 } \input luaotfload.sty \fi -- cgit v1.2.3