1
0
mirror of https://github.com/pdf2htmlEX/pdf2htmlEX.git synced 2024-12-22 04:50:09 +00:00

working on encoding

This commit is contained in:
Lu Wang 2012-08-07 02:37:37 +08:00
parent 910c89c378
commit c9085c5ad4
2 changed files with 15 additions and 0 deletions

View File

@ -12,6 +12,7 @@ echo -n "Converting fonts: "
for f in *.ttf; do
if [ -f $f ]; then
cp $f $f.old
fontforge -script "${SCRIPT_DIR}/convert.pe" $f 2>/dev/null
echo -n "."
fi
@ -19,6 +20,7 @@ done
for f in *.pfa; do
if [ -f $f ]; then
cp $f $f.old
fontforge -script "${SCRIPT_DIR}/convert.pe" $f 2>/dev/null
rm $f
echo -n "."

View File

@ -461,7 +461,20 @@ void HTMLRenderer::drawChar(GfxState *state, double x, double y,
if(uLen > 0)
cur_string->addUnicodes(state, x, y, dx, dy, u, uLen);
else
{
if(nBytes > 0)
{
std::cerr << "Cannot map to Unicode!" << std::endl;
std::cerr << cur_fn_id << std::endl;
std::cerr << "*";
for(int i = 0; i < nBytes; ++i)
{
std::cerr << (int)(((char*)&code)[i]);
}
std::cerr << std::endl;
}
cur_string->addChars(state, x, y, dx, dy, code, nBytes);
}
}
// TODO