ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Vasile Gaburici" <vgaburici@gmail.com>
To: "Taco Hoekwater" <taco@elvenkind.com>
Cc: mailing list for ConTeXt users <ntg-context@ntg.nl>,
	Hans Hagen <pragma@wxs.nl>
Subject: Re: Font problems with latest minimals on Linux
Date: Thu, 14 Aug 2008 08:48:54 +0300	[thread overview]
Message-ID: <bef0d710808132248m1f6ec09cy1939736291c22c2f@mail.gmail.com> (raw)
In-Reply-To: <bef0d710808132133k248d19fdldd0b836b663fec80@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1552 bytes --]

If you still haven't figured out how to reproduce it, apply the
patched I've attached. It will force the hash entries to be added in
sorted order. With the patch applied, if you have some fonts called

Calibri Bold Italic.otf
Calibri Bold.otf
Calibri Italic.otf
Calibri.otf

the order of hash insertions will always exactly as above, regardless
of disk order, e.g.:

filename | 49 -> /usr/share/fonts/vista/C-series/Calibri Bold Italic.otf
filename | 50 -> /usr/share/fonts/vista/C-series/Calibri Bold.otf
filename | 51 -> /usr/share/fonts/vista/C-series/Calibri Italic.otf
filename | 52 -> /usr/share/fonts/vista/C-series/Calibri.otf

So, you'll get bold italic instead of bold in the PDF.

Feel free to fiddle with the sort function if you name fonts
differently, but you need to make sure that bold italic gets loaded
before bold for the bug to occur.

On Thu, Aug 14, 2008 at 7:33 AM, Vasile Gaburici <vgaburici@gmail.com> wrote:
> On Wed, Aug 13, 2008 at 8:00 PM, Taco Hoekwater <taco@elvenkind.com> wrote:
>> Vasile Gaburici wrote:
>>>
>>> Before I get anymore strawman arguments, here's the definitive experiment:
>>
>> As Hans said, should be corrected in the latest beta. Please cut us some
>> slack here, debugging unreproducible problems is hard and timeconsuming.
>
> Okay, I've updated to the latest beta. Recursive OSFONTDIR works now
> for "script --fonts --reload" and for "context", but "script --fonts
> --list" is broken: no output.
>
> The other bug, i.e. embedding bold italic instead of bold for some
> fonts, is still present.
>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: reveal-bold-bug.patch --]
[-- Type: text/x-patch; name=reveal-bold-bug.patch, Size: 1085 bytes --]

diff -up context/tex/texmf-context/tex/context/base/font-syn.lua.nosort context/tex/texmf-context/tex/context/base/font-syn.lua
--- context/tex/texmf-context/tex/context/base/font-syn.lua.nosort	2008-08-14 07:43:48.000000000 +0300
+++ context/tex/texmf-context/tex/context/base/font-syn.lua	2008-08-14 08:46:28.000000000 +0300
@@ -193,8 +193,12 @@ function fonts.names.identify(verbose)
                 local pattern = path .. "**." .. suffix -- ** forces recurse
                 logs.report("fontnames", "globbing path %s",pattern)
                 local t = dir.glob(pattern)
-                for _, name in pairs(t) do -- ipairs
+                table.sort(t, function (str1, str2)
+                                 return str1 < str2
+                              end)
+                for huh, name in pairs(t) do -- ipairs
                 --  if lfs.isfile(name) then -- always true anyway
+                        logs.report("filename", "%d -> %s", huh, name)
                         identify(name,file.basename(name),suffix)
                 --  end
                 end

[-- Attachment #3: Type: text/plain, Size: 487 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

  reply	other threads:[~2008-08-14  5:48 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-12 11:50 Vasile Gaburici
2008-08-13  7:43 ` Taco Hoekwater
2008-08-13  8:31   ` Hans Hagen
2008-08-13  9:21     ` Vasile Gaburici
2008-08-13 10:04       ` Hans Hagen
2008-08-13 10:05   ` Vasile Gaburici
2008-08-13 11:20     ` Hans Hagen
2008-08-13 11:47       ` Vasile Gaburici
2008-08-13 13:46         ` Wolfgang Schuster
2008-08-13 15:49           ` Vasile Gaburici
2008-08-13 16:19             ` Hans Hagen
2008-08-13 17:00             ` Taco Hoekwater
2008-08-14  4:33               ` Vasile Gaburici
2008-08-14  5:48                 ` Vasile Gaburici [this message]
2008-08-14  8:33                   ` Taco Hoekwater
2008-08-14  8:48                   ` Hans Hagen
2008-08-14  9:06                     ` Thomas A. Schmitz
2008-08-13 12:29 ` Taco Hoekwater

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bef0d710808132248m1f6ec09cy1939736291c22c2f@mail.gmail.com \
    --to=vgaburici@gmail.com \
    --cc=gaburici@cs.umd.edu \
    --cc=ntg-context@ntg.nl \
    --cc=pragma@wxs.nl \
    --cc=taco@elvenkind.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).