ChangeLog 108 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606
  1. 2015-11-28 Werner Lemberg <wl@gnu.org>
  2. * Version 2.6.2 released.
  3. =========================
  4. Tag sources with `VER-2-6-2'.
  5. * docs/VERSION.DLL: Update documentation and bump version number to
  6. 2.6.2.
  7. * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
  8. builds/windows/vc2005/index.html,
  9. builds/windows/vc2008/freetype.vcproj,
  10. builds/windows/vc2008/index.html,
  11. builds/windows/vc2010/freetype.vcxproj,
  12. builds/windows/vc2010/index.html,
  13. builds/windows/visualc/freetype.dsp,
  14. builds/windows/visualc/freetype.vcproj,
  15. builds/windows/visualc/index.html,
  16. builds/windows/visualce/freetype.dsp,
  17. builds/windows/visualce/freetype.vcproj,
  18. builds/windows/visualce/index.html,
  19. builds/wince/vc2005-ce/freetype.vcproj,
  20. builds/wince/vc2005-ce/index.html,
  21. builds/wince/vc2008-ce/freetype.vcproj,
  22. builds/wince/vc2008-ce/index.html: s/2.6.1/2.6.2/, s/261/262/.
  23. * include/freetype/freetype.h (FREETYPE_PATCH): Set to 2.
  24. * builds/unix/configure.raw (version_info): Set to 18:2:12.
  25. * CMakeLists.txt (VERSION_PATCH): Set to 2.
  26. * docs/CHANGES: Updated.
  27. 2015-11-28 Werner Lemberg <wl@gnu.org>
  28. Fix C++ compilation.
  29. * src/autofit/afloader.c: Include FT_INTERNAL_CALC_H.
  30. * src/truetype/ttgload.c (load_truetype_glyph): Pacify compiler.
  31. 2015-11-28 Nikolaus Waxweiler <madigens@gmail.com>
  32. Change default LCD filter to be normalized and color-balanced.
  33. * src/base/ftlcdfil.c (FT_Library_SetLcdFilter): Update
  34. `default_filter'.
  35. 2015-11-28 Werner Lemberg <wl@gnu.org>
  36. [docmaker] Allow references to section names.
  37. In the reference, we show the section's title enclosed in single
  38. quotes.
  39. * src/tools/docmaker/formatter.py (Formatter::__init__): Collect
  40. section names as identifiers.
  41. * src/tools/docmaker/tohtml.py (section_title_header): Split into...
  42. (section_title_header1, section_title_header2): ... these two
  43. strings.
  44. (HtmlFormatter::make_block_url, make_html_word, html_source_quote):
  45. Handle sections.
  46. (HtmlFormatter::section_enter): Updated to add `id' HTML attribute.
  47. 2015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
  48. [cmake] Add script to test the config module.
  49. * builds/cmake/testbuild.sh: New file.
  50. 2015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
  51. * CMakeLists.txt: Create `freetype-config.cmake' config module.
  52. 2015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
  53. * CMakeLists.txt: Set CMAKE_DEBUG_POSTFIX to `d'.
  54. 2015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
  55. [cmake] Add better control of library dependencies.
  56. * CMakeLists.txt: Add `WITH_*' variables to force/auto/omit
  57. ZLIB/BZip2/PNG/HarfBuzz.
  58. 2015-11-27 Tamas Kenez <tamas.kenez@adasworks.com>
  59. [cmake] Make `FindHarfbuzz' observe the REQUIRED option.
  60. * builds/cmake/FindHarfBuzz.cmake: Implement it.
  61. 2015-11-27 Werner Lemberg <wl@gnu.org>
  62. [cmake] Collect files specific to cmake in `builds/cmake'.
  63. * builds/FindHarfBuzz.cmake: Move to ...
  64. * builds/cmake/FindHarfBuzz.cmake: ... this place.
  65. * CMakeLists.txt (CMAKE_MODULE_PATH): Updated.
  66. 2015-11-27 Alexander Bock <alexander.j.bock@nasa.gov>
  67. CMakeLists.txt: Honour new command line flag `FREETYPE_NO_DIST'.
  68. 2015-11-26 Werner Lemberg <wl@gnu.org>
  69. [docmaker] Allow `foo[bar]' as identifier.
  70. We need this to handle equally named properties in different
  71. modules.
  72. * src/tools/docmaker/content.py (re_identifier),
  73. src/tools/docmaker/sources.py (re_crossref): Allow `foo[bar]'.
  74. * src/tools/docmaker/tohtml.py (HtmlFormatter::make_html_word,
  75. HtmlFormatter::index_exit, HtmlFormatter::section_enter,
  76. HtmlFormatter::block_enter): Handle `foo[bar]'.
  77. 2015-11-25 Werner Lemberg <wl@gnu.org>
  78. * src/bdf/bdflib.c (bdf_load_font): Fix small memory leak (#46480).
  79. (_bdf_parse_glyphs): Always reset `p->glyph_name' after moving its
  80. contents.
  81. 2015-11-21 Werner Lemberg <wl@gnu.org>
  82. * include/freetype/internal/ftcalc.h: Don't use `register' keyword.
  83. This fixes compiler warnings.
  84. Reported by Behdad.
  85. 2015-11-20 Werner Lemberg <wl@gnu.org>
  86. Add `FT_LCD_FILTER_LEGACY1' enum value.
  87. This does the same as `FT_LCD_FILTER_LEGACY'.
  88. See
  89. https://bugs.freedesktop.org/show_bug.cgi?id=92981
  90. for the reasoning.
  91. * include/freetype/ftlcdfil.h (FT_LcdFilter): New value
  92. `FT_LCD_FILTER_LEGACY1'.
  93. * src/base/ftlcdfil.c (FT_Library_SetLcdFilter): Use it.
  94. 2015-11-15 Werner Lemberg <wl@gnu.org>
  95. * src/autofit/afhints.c (af_get_segment_index): Fix it.
  96. The old code was too simple, returning invalid values in most cases
  97. where a segment crosses the contour start.
  98. 2015-11-15 Werner Lemberg <wl@gnu.org>
  99. * src/bdf/bdflib.c (bdf_load_font): Fix small memory leak (#46439).
  100. 2015-11-11 Werner Lemberg <wl@gnu.org>
  101. [cff, autofit] Switch off stem darkening by default.
  102. * src/autofit/afmodule.c (af_autofitter_init), src/cff/cffobjs.c
  103. (cff_driver_init): Do it.
  104. 2015-11-10 Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
  105. Allow native CFF hinter in FT_RENDER_MODE_LIGHT.
  106. Both the native CFF hinter and the auto-hinter now have a very
  107. similar rendering style.
  108. * include/freetype/freetype.h: Mention that FT_LOAD_TARGET_LIGHT no
  109. longer implies FT_LOAD_FORCE_AUTOHINT.
  110. * include/freetype/ftmodapi.h (FT_MODULE_DRIVER_HINTS_LIGHTLY): New
  111. macro.
  112. * include/freetype/internal/ftobjs.h (FT_DRIVER_HINTS_LIGHTLY): New
  113. macro.
  114. * src/cff/cffdrivr.c (cff_driver_class): Use it.
  115. * src/base/ftobjs.c (FT_Load_Glyph): Update auto-hinter selection
  116. logic.
  117. 2015-11-09 Werner Lemberg <wl@gnu.org>
  118. * src/cid/cidload.c (cid_face_open): Fix GDBytes guard (#46408).
  119. 2015-11-09 Werner Lemberg <wl@gnu.org>
  120. [truetype] Remove integer to pointer conversion compiler warning.
  121. Problem reported by Alexei.
  122. * src/truetype/ttgload.c (load_truetype_glyph): Use a solution found
  123. in the glib library to fix the issue.
  124. 2015-11-08 Behdad Esfahbod <behdad@behdad.org>
  125. [sfnt] Accept version 3 of `EBLC' and `CBLC' tables also.
  126. * src/sfnt/ttsbit.c (tt_face_load_sbit): Implement it.
  127. 2015-11-08 Philipp Knechtges <philipp-dev@knechtges.com>
  128. [autofit] Don't distort (latin) glyphs too much (#46195).
  129. * src/autofit/aflatin.h (AF_LatinBlueRec): Add `ascender' and
  130. `descender' fields.
  131. * src/autofit/aflatin.c (af_latin_metrics_init_blues): Collect
  132. ascender and descender data for blue zones.
  133. (af_latin_metrics_scale_dim): Reject vertical scaling values that
  134. change the result by more than two pixels.
  135. 2015-11-05 Werner Lemberg <wl@gnu.org>
  136. [sfnt] Ignore embedded bitmaps with zero size (#46379).
  137. * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bit_aligned): Implement
  138. it.
  139. 2015-11-04 Werner Lemberg <wl@gnu.org>
  140. [truetype] Catch infinite recursion in subglyphs (#46372).
  141. * include/freetype/internal/tttypes.h (TT_LoaderRec): New field
  142. `composites'.
  143. * src/truetype/ttgload.c: Include FT_LIST_H.
  144. (load_truetype_glyph): Add composite subglyph index to a list;
  145. abort if index is already in list.
  146. (tt_loader_init): Updated.
  147. (tt_loader_done): New function.
  148. (TT_Load_Glyph): Call `tt_loader_done'.
  149. 2015-11-04 Werner Lemberg <wl@gnu.org>
  150. [truetype] Better tracing of composite glyphs.
  151. * src/truetype/ttgload.c (TT_Load_Composite_Glyph,
  152. load_truetype_glyph): Implement it.
  153. 2015-11-03 Werner Lemberg <wl@gnu.org>
  154. [sfnt] Protect against zero-size bitmaps (#46345).
  155. * src/sfnt/ttsbit.c (tt_sbit_decoder_load_bitmap): Check
  156. `glyph_size'.
  157. 2015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
  158. * src/autofit/afloader.c (af_loader_load_g): Implement emboldening.
  159. 2015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
  160. [autofit] Implement darkening computation function.
  161. This is a crude adaption of the original `cf2_computeDarkening'
  162. function.
  163. * src/autofit/afloader.c (af_intToFixed, af_fixedToInt,
  164. af_floatToFixed): New macros, taken from `cf2fixed.h'.
  165. (af_loader_compute_darkening): New function.
  166. * src/autofit/afloader.h: Updated.
  167. 2015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
  168. [autofit] Add functions to get standard widths for writing systems.
  169. We need the computed standard horizontal and vertical widths for the
  170. emboldening calculation. This method provides a convenient way to
  171. extract it from writing-system-specific metrics structures, which
  172. all script definitions must implement.
  173. * src/autofit/aftypes.h (AF_WritingSystem_GetStdWidthsFunc): New
  174. function type.
  175. (AF_WritingSystemClassRec): New member `style_metrics_getstdw'.
  176. (AF_DEFINE_WRITING_SYSTEM_CLASS): Updated.
  177. * src/autofit/afcjk.c (af_cjk_get_standard_width): New function.
  178. (af_cjk_writing_system_class): Updated.
  179. * src/autofit/afdummy.c (af_dummy_writing_system_class): Updated.
  180. * src/autofit/afindic.c (af_cjk_get_standard_width): New function.
  181. (af_indic_writing_system_class): Updated.
  182. * src/autofit/aflatin.c (af_latin_get_standard_width): New function.
  183. (af_indic_writing_system_class): Updated.
  184. * src/autofit/aflatin.c (af_latin_get_standard_width): New function.
  185. (af_indic_writing_system_class): Updated.
  186. 2015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
  187. [autofit] Extend `AF_FaceGlobalsRec' to hold emboldening data.
  188. * src/autofit/afglobal.h (AF_FaceGlobalsRec): Add fields.
  189. * src/autofit/afglobal.c (af_face_globals_new): Initialize new
  190. fields.
  191. (af_face_globals_free): Reset new fields.
  192. 2015-11-02 Nikolaus Waxweiler <madigens@gmail.com>
  193. [autofit] Add stem-darkening properties.
  194. Actual code follows in a later commit.
  195. * include/freetype/ftautoh.h: Document `no-stem-darkening' and
  196. `darkening-parameters'.
  197. * src/autofit/afmodule.h: New fields `no_stem_darkening' and
  198. `darken_params'.
  199. * src/autofit/afmodule.c (af_property_set, af_property_get):
  200. Handle them.
  201. (af_autofitter_init): Initialize them.
  202. 2015-11-02 Bungeman <bungeman@gmail.com>
  203. [ftfuzzer] Add support for multiple files (patch #8779).
  204. Currently, libFuzzer only supports mutation of a single file. We
  205. circumvent this problem by using an uncompressed tar archive as
  206. multiple-file input for the fuzzer.
  207. This patch enables tests of `FT_Attach_Stream' and AFM/PFM parsing;
  208. a constructed tarball should contain a font file as the first
  209. element, and files to be attached as further elements.
  210. * src/tools/ftfuzzer/ftfuzzer.cc: Include libarchive headers.
  211. (archive_read_entry_data, parse_data): New functions.
  212. (LLVMFuzzerTestOneInput): Updated.
  213. * src/tools/ftfuzzer/ftmutator.cc: New file, providing a custom
  214. mutator for libFuzzer that can mutate tarballs in a sensible way.
  215. 2015-10-31 Werner Lemberg <wl@gnu.org>
  216. [sfnt] Fix cmap 14 validation (#46346).
  217. * src/sfnt/ttcmap.c (tt_cmap14_validate): Check limit before
  218. accessing `numRanges' and `numMappings'.
  219. Fix size check for non-default UVS table.
  220. 2015-10-31 Werner Lemberg <wl@gnu.org>
  221. [sfnt] Handle infinite recursion in bitmap strikes (#46344).
  222. * src/sfnt/ttsbit.c (TT_SBitDecoder_LoadFunc,
  223. tt_sbit_decoder_load_bitmap, tt_sbit_decoder_load_byte_aligned,
  224. tt_sbit_decoder_load_bit_aligned, tt_sbit_decoder_load_png): Add
  225. argument for recursion depth.
  226. (tt_sbit_decoder_load_compound): Add argument for recursion depth.
  227. Increase recursion counter for recursive call.
  228. (tt_sbit_decoder_load_image): Add argument for recursion depth.
  229. Check recurse depth.
  230. (tt_face_load_sbit_image): Updated.
  231. 2015-10-29 Werner Lemberg <wl@gnu.org>
  232. * src/autofit/afhints.c (af_glyph_hints_dump_points): Minor.
  233. 2015-10-29 Werner Lemberg <wl@gnu.org>
  234. * CMakeLists.txt: Remove code to set MSVC's /FD compiler switch.
  235. Problem reported by David Capello <davidcapello@gmail.com>; see
  236. http://lists.nongnu.org/archive/html/freetype-devel/2015-10/msg00108.html
  237. for details.
  238. 2015-10-27 Werner Lemberg <wl@gnu.org>
  239. [pfr] Add some safety guards (#46302).
  240. * src/pfr/pfrload.h (PFR_CHECK): Rename to...
  241. (PFR_CHECK_SIZE): ... this.
  242. (PFR_SIZE): [!PFR_CONFIG_NO_CHECKS]: Define to PFR_CHECK_SIZE.
  243. * src/pfr/pfrload.c (pfr_log_font_count): Check `count'.
  244. (pfr_extra_item_load_kerning_pairs): Remove tracing message.
  245. (pfr_phy_font_load): Use PFR_CHECK_SIZE where appropriate.
  246. Allocate `chars' after doing a size checks.
  247. * src/pfr/pfrsbit.c (pfr_load_bitmap_bits): Move test for invalid
  248. bitmap format to...
  249. (pfr_slot_load_bitmap): ... this function.
  250. Check bitmap size.
  251. 2015-10-26 Werner Lemberg <wl@gnu.org>
  252. [truetype] Fix sanitizing logic for `loca' (#46223).
  253. * src/truetype/ttpload.c (tt_face_load_loca): A thinko caused an
  254. incorrect adjustment of the number of glyphs, most often using far
  255. too large values.
  256. 2015-10-25 Werner Lemberg <wl@gnu.org>
  257. [autofit] Improve tracing.
  258. * src/autofit/afhints.c (af_print_idx, af_get_segment_index,
  259. af_get_edge_index): New functions.
  260. (af_glyph_hints_dump_points): Remove unnecessary `|', `[', and `]'.
  261. Add segment and edge index for each point.
  262. Slightly change printing order of some elements.
  263. Don't print `-1' but `--' for missing elements.
  264. (af_glyph_hints_dump_segments, af_glyph_hints_dump_edges): Remove
  265. unnecessary `|', `[', and `]'.
  266. Don't print `-1' but `--' for missing elements.
  267. 2015-10-24 Werner Lemberg <wl@gnu.org>
  268. [sfnt] Sanitize bitmap strike glyph height.
  269. Problem reported by Nikolay Sivov <bunglehead@gmail.com>.
  270. * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Avoid zero value
  271. for `metrics->height' by applying some heuristics.
  272. 2015-10-22 Werner Lemberg <wl@gnu.org>
  273. [sfnt, type42] Fix clang compiler warnings.
  274. * src/sfnt/sfobjs.c (sfnt_init_face): Initialize `offset'.
  275. * src/type42/t42parse.c (t42_parse_sfnts): Use proper cast.
  276. 2015-10-22 Dave Arnold <darnold@adobe.com>
  277. Werner Lemberg <wl@gnu.org>
  278. [cff] Avoid overflow/module arithmetic.
  279. This modifies the addition of subroutine number to subroutine bias
  280. from unsigned to signed, but does not change any results.
  281. * src/cff/cf2ft.c (cf2_initGlobalRegionBuffer,
  282. cf2_initLocalRegionBuffer): Change variable names from (unsigned)
  283. `idx' to (signed) `subrNum', since it is not an index until after
  284. the bias is added.
  285. * src/cff/cf2ft.h: Updated.
  286. * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdCALLSUBR>:
  287. Updated similarly.
  288. 2015-10-22 Werner Lemberg <wl@gnu.org>
  289. [cid] Better check of `SubrCount' dictionary entry (#46272).
  290. * src/cid/cidload.c (cid_face_open): Add more sanity tests for
  291. `fd_bytes', `gd_bytes', `sd_bytes', and `num_subrs'.
  292. 2015-10-21 Werner Lemberg <wl@gnu.org>
  293. [base] Pacify compiler (#46266).
  294. * src/base/ftoutln.c (FT_Outline_EmboldenXY): Initialize `in' and
  295. `anchor'.
  296. 2015-10-21 Werner Lemberg <wl@gnu.org>
  297. [type42] Fix heap buffer overflow (#46269).
  298. * src/type42/t42parse.c (t42_parse_sfnts): Fix off-by-one error in
  299. bounds checking.
  300. 2015-10-21 Dave Arnold <darnold@adobe.com>
  301. [cff] Fix limit in assert for max hints.
  302. * src/cff/cf2interp.c (cf2_hintmask_setAll): Allow mask equal to the
  303. limit (96 bits).
  304. 2015-10-21 Dave Arnold <darnold@adobe.com>
  305. [cff] Remove an assert (#46107).
  306. * src/cff/cf2hints.c (cf2_hintmap_insertHint): Ignore paired edges
  307. in wrong order.
  308. 2015-10-21 Werner Lemberg <wl@gnu.org>
  309. [sfnt] Avoid unnecessarily large allocation for WOFFs (#46257).
  310. * src/sfnt/sfobjs.c (woff_open_font): Use WOFF's `totalSfntSize'
  311. only after thorough checks.
  312. Add tracing messages.
  313. 2015-10-21 Werner Lemberg <wl@gnu.org>
  314. [type42] Better check invalid `sfnts' array data (#46255).
  315. * src/type42/t42parse.c (t42_parse_sfnts): Table lengths must be
  316. checked individually against available data size.
  317. 2015-10-20 Werner Lemberg <wl@gnu.org>
  318. [cid] Add a bunch of safety checks.
  319. * src/cid/cidload.c (parse_fd_array): Check `num_dicts' against
  320. stream size.
  321. (cid_read_subrs): Check largest offset against stream size.
  322. (cid_parse_dict): Move safety check to ...
  323. (cid_face_open): ... this function.
  324. Also test length of binary data and values of `SDBytes',
  325. `SubrMapOffset', `SubrCount', `CIDMapOffset', and `CIDCount'.
  326. 2015-10-20 Werner Lemberg <wl@gnu.org>
  327. [cid] Avoid segfault with malformed input (#46250).
  328. * src/cid/cidload.c (cid_read_subrs): Return a proper error code for
  329. unsorted offsets.
  330. 2015-10-20 StudioEtrange <nomorgan@gmail.com>
  331. * CMakeLists.txt: Enable shared library builds on MinGW (#46233).
  332. 2015-10-20 Werner Lemberg <wl@gnu.org>
  333. * src/type1/t1afm.c (T1_Read_Metrics): Fix memory leak (#46229).
  334. 2015-10-19 Bungeman <bungeman@gmail.com>
  335. [cid] Better handle invalid glyph stream offsets (#46221).
  336. * src/cid/cidgload.c (cid_load_glyph): Check minimum size of glyph
  337. length.
  338. 2015-10-18 Werner Lemberg <wl@gnu.org>
  339. [psaux] Fix tracing of negative numbers.
  340. Due to incorrect casting negative numbers were shown as very large
  341. (positive) integers on 64bit systems.
  342. * src/psaux/t1decode.c (t1_decoder_parse_charstrings) <op_none>:
  343. Use division instead of shift.
  344. 2015-10-18 Werner Lemberg <wl@gnu.org>
  345. [truetype] Improve TT_CONFIG_OPTION_MAX_RUNNABLE_OPCODES (#46223).
  346. * devel/ftoption.h, include/freetype/config/ftoption.h: Surround it
  347. with #ifndef ... #endif, as suggested in the tracker issue.
  348. 2015-10-18 Werner Lemberg <wl@gnu.org>
  349. [truetype] Better protection against malformed `fpgm' (#46223).
  350. * src/truetype/ttobjs.c (tt_size_init_bytecode): Don't execute a
  351. malformed `fpgm' table more than once.
  352. 2015-10-17 Werner Lemberg <wl@gnu.org>
  353. * src/cid/cidgload.c (cid_load_glyph): Fix memory leak.
  354. Reported by Kostya Serebryany <kcc@google.com>.
  355. 2015-10-17 Werner Lemberg <wl@gnu.org>
  356. [bdf] Prevent memory leak (#46217).
  357. * src/bdf/bdflib.c (_bdf_parse_glyphs) <STARTCHAR>: Check
  358. _BDF_GLYPH_BITS.
  359. 2015-10-17 Werner Lemberg <wl@gnu.org>
  360. [bdf] Use stream size to adjust number of glyphs.
  361. * src/bdf/bdflib.c (ACMSG17): New message macro.
  362. (_bdf_parse_t): Add member `size'.
  363. (bdf_load_font): Set `size'.
  364. (_bdf_parse_glyphs): Adjust `cnt' if necessary.
  365. 2015-10-17 Werner Lemberg <wl@gnu.org>
  366. * src/cid/cidload.c (cid_parse_dict): Check `[FG]DBytes' size.
  367. 2015-10-17 Werner Lemberg <wl@gnu.org>
  368. * src/cid/cidgload.c (cid_glyph_load): Check file offsets (#46222).
  369. 2015-10-17 Werner Lemberg <wl@gnu.org>
  370. [psaux] Fix heap buffer overflow (#46221).
  371. * src/psaux/t1decode.c (t1_decoder_parse_charstring) <operator 12>:
  372. Fix limit check.
  373. 2015-10-17 Werner Lemberg <wl@gnu.org>
  374. * src/cid/cidload.c (cid_parse_dict): Handle invalid input (#46220).
  375. 2015-10-15 Kostya Serebryany <kcc@google.com>
  376. [ftfuzzer] Add README.
  377. * src/tools/ftfuzzer/README: New file.
  378. 2015-10-15 Bungeman <bungeman@gmail.com>
  379. [bdf] Fix memory leak (#46213).
  380. * src/bdf/bdflib.c (bdf_load_font): Always go to label `Fail' in
  381. case of error.
  382. 2015-10-15 Werner Lemberg <wl@gnu.org>
  383. [truetype] Add TT_CONFIG_OPTION_MAX_RUNNABLE_OPCODES (#46208).
  384. * devel/ftoption.h, include/freetype/config/ftoption.h
  385. (TT_CONFIG_OPTION_MAX_RUNNABLE_OPCODES): New configuration macro.
  386. * src/truetype/ttinterp.c (MAX_RUNNABLE_OPCODES): Removed.
  387. (TT_RunIns): Updated.
  388. 2015-10-15 Werner Lemberg <wl@gnu.org>
  389. * src/truetype/ttinterp.c (TT_RunIns): Fix bytecode stack tracing.
  390. The used indices were off by 1.
  391. 2015-10-15 Bungeman <bungeman@gmail.com>
  392. Werner Lemberg <wl@gnu.org>
  393. * src/tools/ftfuzzer/ftfuzzer.cc: Handle fixed sizes (#46211).
  394. 2015-10-15 Werner Lemberg <wl@gnu.org>
  395. [base] Compute MD5 checksums only if explicitly requested.
  396. This improves profiling accuracy.
  397. * src/base/ftobjs.c (FT_Render_Glyph_Internal): Implement it.
  398. 2015-10-14 Werner Lemberg <wl@gnu.org>
  399. [base] Use `FT_' namespace for MD5 functions (#42366).
  400. * src/base/ftobjs.c (MD5_*): Define as `FT_MD5_*'.
  401. Undefine HAVE_OPENSSL.
  402. 2015-10-13 Werner Lemberg <wl@gnu.org>
  403. [type1] Correctly handle missing MM axis names (#46202).
  404. * src/type1/t1load.c (T1_Get_MM_Var): Implement it.
  405. 2015-10-13 Werner Lemberg <wl@gnu.org>
  406. [pcf] Quickly exit if font index < 0.
  407. Similar to other font formats, this commit makes the parser no
  408. longer check the whole PCF file but only the header and the TOC if
  409. we just want to get the number of available faces (and a proper
  410. recognition of the font format).
  411. * src/pcf/pcfdrivr.c (PCF_Face_Init): Updated.
  412. Exit quickly if face_index < 0.
  413. * src/pcfread.c (pcf_load_font): Add `face_index' argument.
  414. Exit quickly if face_index < 0.
  415. * src/pcf/pcf.h: Updated.
  416. 2015-10-13 Werner Lemberg <wl@gnu.org>
  417. [ftfuzzer] Handle TTCs and MM/GX variations.
  418. This patch also contains various other improvements.
  419. * src/tools/ftfuzzer/ftfuzzer.cc: Add preprocessor guard to reject
  420. pre-C++11 compilers.
  421. (FT_Global): New class. Use it to provide a global constructor and
  422. destructor for the `FT_Library' object.
  423. (setIntermediateAxis): New function to select an (arbitrary)
  424. instance.
  425. (LLVMFuzzerTestOneInput): Loop over all faces and named instances.
  426. Also call `FT_Set_Char_Size'.
  427. 2015-10-13 Werner Lemberg <wl@gnu.org>
  428. [truetype] Refine some GX sanity tests.
  429. Use the `gvar' table size instead of the remaining bytes in the
  430. stream.
  431. * src/truetype/ttgxvar.h (GX_BlendRec): New field `gvar_size'.
  432. * src/truetype/ttgxvar.c (ft_var_load_gvar): Set `gvar_size'.
  433. (ft_var_readpackedpoints, ft_var_readpackeddeltas: New argument
  434. `size'.
  435. (tt_face_vary_cvt, TT_Vary_Apply_Glyph_Deltas): Updated.
  436. 2015-10-13 Werner Lemberg <wl@gnu.org>
  437. [truetype] Another GX sanity test.
  438. * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Check
  439. `tupleCount'.
  440. Add tracing message.
  441. 2015-10-13 Werner Lemberg <wl@gnu.org>
  442. [truetype] Fix memory leak for broken GX fonts (#46188).
  443. * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Fix scope of
  444. deallocation.
  445. 2015-10-13 Werner Lemberg <wl@gnu.org>
  446. [truetype] Fix commit from 2015-10-10.
  447. * src/truetype/ttgxvar.c (ft_var_load_gvar): Add missing error
  448. handling body to condition.
  449. 2015-10-12 Werner Lemberg <wl@gnu.org>
  450. [unix] Make MKDIR_P actually work.
  451. * builds/unix/configure.raw: Fix underquoting of `INSTALL' and
  452. `MKDIR_P'.
  453. Problem reported by Dan Liddell <lddll@yahoo.com>.
  454. 2015-10-11 Werner Lemberg <wl@gnu.org>
  455. [sfnt] Improve extraction of number of named instances.
  456. * src/sfnt/sfobjs.c (sfnt_init_face)
  457. [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Check number of instances against
  458. `fvar' table size.
  459. 2015-10-10 Alexei Podtelezhnikov <apodtele@gmail.com>
  460. * src/base/ftoutln.c (FT_Outline_Get_Orientation): Fix overflow
  461. (#46149).
  462. 2015-10-10 Werner Lemberg <wl@gnu.org>
  463. [sfnt] Fix infinite loops with broken cmaps (#46167).
  464. * src/sfnt/ttcmap.c (tt_cmap8_char_next, tt_cmap12_next): Take care
  465. of border conditions (i.e., if the loops exit naturally).
  466. 2015-10-10 Werner Lemberg <wl@gnu.org>
  467. [truetype] More sanity tests for GX handling.
  468. These tests should mainly help avoid unnecessarily large memory
  469. allocations in case of malformed fonts.
  470. * src/truetype/ttgxvar.c (ft_var_readpackedpoints,
  471. ft_var_readpackeddeltas): Check number of points against stream
  472. size.
  473. (ft_var_load_avar): Check `pairCount' against table length.
  474. (ft_var_load_gvar): Check `globalCoordCount' and `glyphCount'
  475. against table length.
  476. (tt_face_vary_cvt): Check `tupleCount' and `offsetToData'.
  477. Fix trace.
  478. (TT_Vary_Apply_Glyph_Deltas): Fix trace.
  479. Free `sharedpoints' to avoid memory leak.
  480. 2015-10-10 Werner Lemberg <wl@gnu.org>
  481. [truetype] Better protection against malformed GX data (#46166).
  482. * src/truetype/ttgxvar.c (TT_Vary_Apply_Glyph_Deltas): Correctly
  483. handle empty `localpoints' array.
  484. 2015-10-10 Werner Lemberg <wl@gnu.org>
  485. * src/pcf/pcfread.c (pcf_read_TOC): Check stream size (#46162).
  486. 2015-10-09 Werner Lemberg <wl@gnu.org>
  487. * src/gzip/ftgzip.c (FT_Stream_OpenGzip): Use real stream size.
  488. 2015-10-08 Werner Lemberg <wl@gnu.org>
  489. [pcf] Protect against invalid number of TOC entries (#46159).
  490. * src/pcf/pcfread.c (pcf_read_TOC): Check number of TOC entries
  491. against size of data stream.
  492. 2015-10-08 Werner Lemberg <wl@gnu.org>
  493. [type42] Protect against invalid number of glyphs (#46159).
  494. * src/type42/t42parse.c (t42_parse_charstrings): Check number of
  495. `CharStrings' dictionary entries against size of data stream.
  496. 2015-10-08 Werner Lemberg <wl@gnu.org>
  497. [sfnt] Fix some signed overflows (#46149).
  498. * src/sfnt/ttsbit.c (tt_face_load_strike_metrics)
  499. <TT_SBIT_TABLE_TYPE_SBIX>: Use `FT_MulDiv'.
  500. 2015-10-08 Werner Lemberg <wl@gnu.org>
  501. [type1] Protect against invalid number of subroutines (#46150).
  502. * src/type1/t1load.c (parse_subrs): Check number of
  503. `Subrs' dictionary entries against size of data stream.
  504. 2015-10-07 Kostya Serebryany <kcc@google.com>
  505. [ftfuzzer] Add support for LLVM's LibFuzzer.
  506. * src/tools/ftfuzzer/ftfuzzer.cc, src/tools/runinput.cc: New files.
  507. 2015-10-06 Alexei Podtelezhnikov <apodtele@gmail.com>
  508. [smooth] Faster alternative line renderer.
  509. This implementation renders the entire line segment at once without
  510. subdividing it into scanlines. The main speed improvement comes from
  511. reducing the number of divisions to just two per line segment, which
  512. is a bare minimum to calculate cell coverage in a smooth rasterizer.
  513. Notably, the progression from cell to cell does not itself require any
  514. divisions at all. The speed improvement is more noticeable at larger
  515. sizes.
  516. * src/smooth/ftgrays.c (gray_render_line): New implementation.
  517. 2015-10-06 Werner Lemberg <wl@gnu.org>
  518. [cff] Return correct PS names from pure CFF (#46130).
  519. * src/cff/cffdrivr.c (cff_get_ps_name): Use SFNT service only for
  520. SFNT.
  521. 2015-10-04 Werner Lemberg <wl@gnu.org>
  522. [base] Replace left shifts with multiplication (#46118).
  523. * src/base/ftglyph.c (ft_bitmap_glyph_bbox, FT_Get_Glyph): Do it.
  524. 2015-10-04 Werner Lemberg <wl@gnu.org>
  525. * Version 2.6.1 released.
  526. =========================
  527. Tag sources with `VER-2-6-1'.
  528. * docs/VERSION.DLL: Update documentation and bump version number to
  529. 2.6.1.
  530. * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
  531. builds/windows/vc2005/index.html,
  532. builds/windows/vc2008/freetype.vcproj,
  533. builds/windows/vc2008/index.html,
  534. builds/windows/vc2010/freetype.vcxproj,
  535. builds/windows/vc2010/index.html,
  536. builds/windows/visualc/freetype.dsp,
  537. builds/windows/visualc/freetype.vcproj,
  538. builds/windows/visualc/index.html,
  539. builds/windows/visualce/freetype.dsp,
  540. builds/windows/visualce/freetype.vcproj,
  541. builds/windows/visualce/index.html,
  542. builds/wince/vc2005-ce/freetype.vcproj,
  543. builds/wince/vc2005-ce/index.html,
  544. builds/wince/vc2008-ce/freetype.vcproj,
  545. builds/wince/vc2008-ce/index.html: s/2.6/2.6.1/, s/26/261/.
  546. * include/freetype/freetype.h (FREETYPE_PATCH): Set to 1.
  547. * builds/unix/configure.raw (version_info): Set to 18:1:12.
  548. * CMakeLists.txt (VERSION_PATCH): Set to 1.
  549. * src/autofit/afmodule.c [AF_DEBUG_AUTOFIT]: Ensure C linking for
  550. dumping functions.
  551. 2015-10-04 Werner Lemberg <wl@gnu.org>
  552. [bzip2, gzip] Avoid access of unitialized memory (#46109).
  553. * src/bzip2/ftbzip2.c (ft_bzip2_file_fill_input), src/gzip/ftgzip.c
  554. (ft_gzip_file_fill_input): In case of an error, adjust the limit to
  555. avoid copying uninitialized memory.
  556. 2015-10-03 Werner Lemberg <wl@gnu.org>
  557. [bzip2, gzip] Avoid access of unitialized memory (#46109).
  558. * src/bzip2/ftbzip2.c (ft_bzip2_file_fill_output), src/gzip/ftgzip.c
  559. (ft_gzip_file_fill_output): In case of an error, adjust the limit to
  560. avoid copying uninitialized memory.
  561. 2015-10-01 Alexei Podtelezhnikov <apodtele@gmail.com>
  562. [smooth] Clean up worker.
  563. * src/smooth/ftgrays.c (gray_TWorker): Remove never used fields.
  564. 2015-10-01 Werner Lemberg <wl@gnu.org>
  565. [sfnt] Make `tt_cmap4_char_map_linear' more robust (#46078).
  566. * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Take care of
  567. border conditions (i.e., if the loop exits naturally).
  568. 2015-10-01 Werner Lemberg <wl@gnu.org>
  569. * src/autofit/afranges.c (af_deva_nonbase_uniranges): Fix ranges.
  570. They should be a subset of `af_deva_uniranges'.
  571. 2015-10-01 Werner Lemberg <wl@gnu.org>
  572. [sfnt] Make `tt_cmap4_char_map_linear' faster (#46078).
  573. * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Use inner loop to
  574. reject too large glyph indices.
  575. 2015-09-30 Alexei Podtelezhnikov <apodtele@gmail.com>
  576. [smooth] Clean up worker.
  577. * src/smooth/ftgrays.c (gray_TWorker): Remove lightly used `last_ey'.
  578. (gray_start_cell, gray_render_line): Update.
  579. 2015-09-30 Werner Lemberg <wl@gnu.org>
  580. [autofit] Replace `no-base' with `non-base'.
  581. * src/autofit/*: Do it.
  582. 2015-09-30 Werner Lemberg <wl@gnu.org>
  583. [sfnt] Rewrite `tt_cmap4_char_map_linear' (#46078).
  584. * src/sfnt/ttcmap.c (tt_cmap4_char_map_linear): Add code to better
  585. skip invalid segments.
  586. If searching the next character, provide a more efficient logic to
  587. speed up the code.
  588. 2015-09-30 Werner Lemberg <wl@gnu.org>
  589. [truetype] Adjust number of glyphs for malformed `loca' tables.
  590. * src/truetype/ttpload.c (tt_face_load_loca): Implement it.
  591. 2015-09-29 Werner Lemberg <wl@gnu.org>
  592. [pshinter] Avoid harmless overflow (#45984).
  593. * src/pshinter/pshglob.c (psh_blues_set_zones): Fix it.
  594. 2015-09-28 Werner Lemberg <wl@gnu.org>
  595. [autofit] Add support for Lao script.
  596. Thanks to Danh Hong <danhhong@gmail.com> for guidance with blue zone
  597. characters!
  598. * src/autofit/afblue.dat: Add blue zone data for Lao.
  599. * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
  600. * src/autofit/afscript.h: Add Lao standard characters.
  601. * src/autofit/afranges.c: Add Lao data.
  602. * src/autofit/afstyles.h: Add Lao data.
  603. 2015-09-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
  604. [base] Fix a leak by broken sfnt-PS or resource fork (#46028).
  605. open_face_from_buffer() frees passed buffer if valid font
  606. is not found. But if copying to the buffer is failed,
  607. the allocated buffer should be freed within the caller.
  608. * src/base/ftobjs.c (open_face_PS_from_sfnt_stream): Free
  609. the buffer `sfnt_ps' if an error caused before calling
  610. open_face_from_buffer().
  611. (Mac_Read_sfnt_Resource): Free the buffer `sfnt_data' if
  612. an error caused before calling open_face_from_buffer();
  613. 2015-09-27 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
  614. [mac] Fix buffer size calculation for LWFN font.
  615. * src/base/ftmac.c (read_lwfn): Cast post_size to FT_ULong
  616. to prevent confused copy by too large chunk size.
  617. 2015-09-26 Alexei Podtelezhnikov <apodtele@gmail.com>
  618. * src/smooth/ftgrays.c (PIXEL_MASK): Remove unused macro.
  619. 2015-09-26 Werner Lemberg <wl@gnu.org>
  620. [autofit] Minor tracing improvement.
  621. * src/autofit/aflatin.c (af_latin_metrics_scale_dim): Don't emit
  622. blue zones header line if there are no blue zones.
  623. 2015-09-26 Werner Lemberg <wl@gnu.org>
  624. [bzip2, gzip, lzw] Harmonize function signatures with prototype.
  625. Suggested by Hin-Tak Leung.
  626. * src/bzip2/ftbzip2.c (ft_bzip2_stream_io), src/gzip/ftgzip.c
  627. (ft_gzip_stream_io), src/lzw/ftlzw.c (ft_lzw_stream_io): Do it.
  628. 2015-09-26 Hin-Tak Leung <htl10@users.sourceforge.net>
  629. Add new FT_LOAD_COMPUTE_METRICS load flag.
  630. * include/freetype/freetype.h (FT_LOAD_COMPUTE_METRICS): New macro.
  631. * src/truetype/ttgload.c (compute_glyph_metrics): Usage.
  632. 2015-09-26 Werner Lemberg <wl@gnu.org>
  633. * src/base/ftobjs.c (Mac_Read_sfnt_Resource): Add cast.
  634. 2015-09-25 Werner Lemberg <wl@gnu.org>
  635. [type1] Protect against invalid number of glyphs (#46029).
  636. * src/type1/t1load.c (parse_charstrings): Check number of
  637. `CharStrings' dictionary entries against size of data stream.
  638. 2015-09-23 Werner Lemberg <wl@gnu.org>
  639. [sfnt] Better checks for invalid cmaps (2/2) (#46019).
  640. While the current code in `FT_Get_Next_Char' correctly rejects
  641. out-of-bounds glyph indices, it can be extremely slow for malformed
  642. cmaps that use 32bit values. This commit tries to improve that.
  643. * src/sfnt/ttcmap.c (tt_cmap8_char_next, tt_cmap12_next,
  644. tt_cmap12_char_map_binary, tt_cmap13_next,
  645. tt_cmap13_char_map_binary): Reject glyph indices larger than or
  646. equal to the number of glyphs.
  647. 2015-09-23 Werner Lemberg <wl@gnu.org>
  648. [base, sfnt] Better checks for invalid cmaps (1/2).
  649. * src/base/ftobjs.c (FT_Get_Char_Index): Don't return out-of-bounds
  650. glyph indices.
  651. (FT_Get_First_Char): Updated.
  652. * src/sfnt/ttcmap.c (tt_cmap6_char_next): Don't return character
  653. codes greater than 0xFFFF.
  654. (tt_cmap8_char_index): Avoid integer overflow in computation of
  655. glyph index.
  656. (tt_cmap8_char_next): Avoid integer overflows in computation of
  657. both next character code and glyph index.
  658. (tt_cmap10_char_index): Fix unsigned integer logic.
  659. (tt_cmap10_char_next): Avoid integer overflow in computation of
  660. next character code.
  661. (tt_cmap12_next): Avoid integer overflows in computation of both
  662. next character code and glyph index.
  663. (tt_cmap12_char_map_binary): Ditto.
  664. (tt_cmap12_char_next): Simplify.
  665. (tt_cmap13_char_map_binary): Avoid integer overflow in computation
  666. of next character code.
  667. (tt_cmap13_char_next): Simplify.
  668. 2015-09-21 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
  669. [base] Check too long POST and sfnt resource (#45919).
  670. * src/base/ftbase.h (FT_MAC_RFORK_MAX_LEN): Maximum length of the
  671. resource fork for Mac OS. Resource forks larger than 16 MB can be
  672. written but can't be handled correctly, at least in Carbon routine.
  673. See https://support.microsoft.com/en-us/kb/130437.
  674. * src/base/ftobjs.c (Mac_Read_POST_Resource): No need to use `0x'
  675. prefix for `%p' formatter.
  676. * src/base/ftbase.c (Mac_Read_POST_Resource): Check the fragment and
  677. total size of the concatenated POST resource before buffer
  678. allocation.
  679. (Mac_Read_sfnt_Resource): Check the declared size of sfnt resource
  680. before buffer allocation.
  681. * src/base/ftmac.c (read_lwfn, FT_New_Face_From_SFNT): Check the
  682. total resource size before buffer allocation.
  683. 2015-09-19 Werner Lemberg <wl@gnu.org>
  684. [sfnt] Improve handling of invalid SFNT table entries (#45987).
  685. This patch fixes weaknesses in function `tt_face_load_font_dir'.
  686. - It incorrectly assumed that valid tables are always at the
  687. beginning. As a consequence, some valid tables after invalid
  688. entries (which are ignored) were never seen.
  689. - Duplicate table entries (this is, having the same tag) were not
  690. rejected.
  691. - The number of valid tables was sometimes too large, leading to
  692. access of invalid tables.
  693. * src/sfnt/ttload.c (check_table_dir): Add argument to return number
  694. of valid tables.
  695. Add another tracing message.
  696. (tt_face_load_font_dir): Only allocate table array for valid
  697. entries as returned by `check_table_dir'.
  698. Reject duplicate tables and adjust number of valid tables
  699. accordingly.
  700. 2015-09-19 Werner Lemberg <wl@gnu.org>
  701. [pcf] Improve `FT_ABS' fix from 2015-09-17 (#45999).
  702. * src/pcf/pcfread.c (pcf_load_font): Do first the cast to FT_Short,
  703. then take the absolute value.
  704. Also apply FT_ABS to `height'.
  705. 2015-09-17 Werner Lemberg <wl@gnu.org>
  706. [type42] Fix memory leak (#45989).
  707. * src/type42/t42parse.c (t42_parse_charstrings): Allow only a single
  708. `CharStrings' array.
  709. 2015-09-17 Werner Lemberg <wl@gnu.org>
  710. [psaux] Fix memory leak (#45986).
  711. * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
  712. Free `temp' in case of error.
  713. 2015-09-17 Werner Lemberg <wl@gnu.org>
  714. [psaux] Improve tracing message.
  715. * src/psaux/psobjs.c (ps_parser_load_field) <T1_FIELD_TYPE_MM_BBOX>:
  716. Handle plural correctly.
  717. 2015-09-17 Werner Lemberg <wl@gnu.org>
  718. [pcf] Fix integer overflows (#45985).
  719. * src/pcf/pcfread.c (pcf_load_font): Use FT_MulDiv.
  720. 2015-09-17 Werner Lemberg <wl@gnu.org>
  721. [pcf] Use FT_ABS for some property values (#45893).
  722. * src/pcf/pcfread.c (pcf_load_font): Take absolute values for
  723. AVERAGE_WIDTH, POINT_SIZE, PIXEL_SIZE, RESOLUTION_X, and
  724. RESOLUTION_Y. In tracing mode, add warnings.
  725. 2015-09-16 Werner Lemberg <wl@gnu.org>
  726. Minor fixes for some clang warnings.
  727. * src/base/ftoutln.c (FT_Outline_EmboldenXY): Cast, possible missing
  728. initialization.
  729. * src/truetype/ttgload.c (TT_Process_Composite_Component): Cast.
  730. 2015-09-15 Werner Lemberg <wl@gnu.org>
  731. [type1, type42] Fix memory leaks (#45966).
  732. * src/type1/t1load.c (parse_blend_axis_types): Handle multiple axis
  733. names.
  734. (parse_blend_design_map): Allow only a single design map.
  735. (parse_encoding): Handle multiple encoding vectors.
  736. * src/type42/t42parse.c (t42_parse_encoding): Handle multiple
  737. encoding vectors.
  738. 2015-09-15 Werner Lemberg <wl@gnu.org>
  739. [truetype] Fix integer type (#45965).
  740. * src/truetype/ttobjs.c (tt_synth_sfnt_checksum): Implement it.
  741. 2015-09-15 Werner Lemberg <wl@gnu.org>
  742. * src/pcf/pcfread.c (pcf_load_font): Fix integer overflow (#45964).
  743. 2015-09-15 Werner Lemberg <wl@gnu.org>
  744. [type1, type42] Check encoding array size (#45961).
  745. * src/type1/t1load.c (parse_encoding), src/type42/t42parse.c
  746. (t42_parse_encoding): Do it.
  747. 2015-09-14 Alexei Podtelezhnikov <apodtele@gmail.com>
  748. * src/base/ftcalc.c (FT_MulFix) [FT_LONG64]: Improve.
  749. 2015-09-14 Werner Lemberg <wl@gnu.org>
  750. [type1] Fix another potential buffer overflow (#45955).
  751. * src/type1/t1parse (T1_Get_Private_Dict): Assure that check for
  752. `eexec' doesn't exceed `limit'.
  753. 2015-09-13 Werner Lemberg <wl@gnu.org>
  754. Replace `mkinstalldirs' with AC_PROG_MKDIR_P.
  755. * builds/unix/mkinstalldirs: Removed, no longer needed.
  756. * builds/unix/configure.raw: Call `AC_PROG_MKDIR_P'.
  757. Update pwd call for `$INSTALL'.
  758. * builds/unix/unix-def.in (MKINSTALLDIRS): Use `@MKDIR_P@'.
  759. * autogen.sh: Updated.
  760. 2015-09-13 Werner Lemberg <wl@gnu.org>
  761. [winfonts] Check alignment shift count for resource data (#45938).
  762. * src/winfonts/winfnt.c (fnt_face_get_dll_font): Implement it.
  763. 2015-09-13 Werner Lemberg <wl@gnu.org>
  764. [type1] Fix potential buffer overflow (#45923).
  765. * src/type1/t1parse.c (T1_Get_Private_Dict): Assure `cur' doesn't
  766. point to end of file buffer.
  767. 2015-09-13 Werner Lemberg <wl@gnu.org>
  768. [gzip] Fix access of small compressed files (#45937).
  769. * src/gzip/ftgzip.c (ft_gzip_stream_close): Avoid memory leak.
  770. (ft_gzip_get_uncompressed_file): Correct byte order while reading
  771. unsigned long value. Without this change, the whole optimization of
  772. accessing small files in `FT_Stream_OpenGzip' is never executed! As
  773. a consequence, access to PCF files in general (which are normally
  774. small files) should be much improved now as originally intended.
  775. 2015-09-11 Werner Lemberg <wl@gnu.org>
  776. [psaux] Fix potential buffer overflow (#45922).
  777. * src/psaux/psobjs.c (ps_parser_skip_PS_token): If a token is
  778. enclosed in balanced expressions, ensure that the cursor position
  779. doesn't get larger than the current limit.
  780. 2015-09-11 Werner Lemberg <wl@gnu.org>
  781. [base] Avoid crash while tracing `load_mac_face'.
  782. Reported in Savannah bug #45919.
  783. * src/base/ftobjs.c (load_mac_face): Honour FT_OPEN_MEMORY while
  784. tracing.
  785. 2015-09-11 Werner Lemberg <wl@gnu.org>
  786. [type42] Fix endless loop (#45920).
  787. * src/type42/t42parse.c (t42_parse_encoding): Synchronize with
  788. type1's `parse_encoding'.
  789. 2015-09-10 Werner Lemberg <wl@gnu.org>
  790. [docmaker] Allow `-' in bold and italic markup.
  791. * src/tools/docmaker/sources.py (re_italic, re_bold): Adjust
  792. accordingly.
  793. 2015-09-09 Alexei Podtelezhnikov <apodtele@gmail.com>
  794. * src/base/ftcalc.c (FT_RoundFix): Improve.
  795. 2015-09-09 Wojciech Mamrak <wmamrak@gmail.com>
  796. * src/base/ftcalc.c (FT_CeilFix, FT_FloorFix): Normalize.
  797. This commit makes the functions behave as expected, this is,
  798. rounding towards plus or minus infinity.
  799. 2015-09-07 Alexei Podtelezhnikov <apodtele@gmail.com>
  800. * src/smooth/ftgrays.c (gray_render_line): Simplify clipping.
  801. 2015-09-04 Alexei Podtelezhnikov <apodtele@gmail.com>
  802. [raster,smooth] Microoptimizations.
  803. * src/raster/ftraster.c (Insert_Y_Turn, Finalize_Profile_Table,
  804. Beziier_Up, ): Use do-while loops.
  805. * src/smooth/ftgrays.c (gray_render_scanline, gray_render_line,
  806. gray_convert_glyph): Ditto.
  807. 2015-09-04 Werner Lemberg <wl@gnu.org>
  808. [autofit] Redesign code ranges (2/2).
  809. This commit adds two fallback scripts (`latb', `latp') and
  810. implements support for the no-base character ranges introduced in
  811. the previous commit.
  812. * src/autofit/aftypes.h (AF_ScriptClassRec): Add
  813. `script_uni_nobase_ranges' field.
  814. (AF_DEFINE_SCRIPT_CLASS): Updated.
  815. * src/autofit/afscript.h, src/autofit/afstyles.h: Add `latb' and
  816. `latp' fallback scripts.
  817. * src/autofit/afblue.dat: Add blue zones for Latin subscript and
  818. superscript fallback scripts.
  819. * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
  820. * src/autofit/afglobal.h (AF_NOBASE): New style flag for no-base
  821. characters.
  822. (AF_STYLE_MASK): Updated.
  823. * src/autofit/afglobal.c (SCRIPT): Updated.
  824. (af_face_globals_compute_style_coverage): Handle new style flag.
  825. * src/autofit/aflatin.c (af_latin_hints_apply): Handle new style
  826. flag.
  827. * src/autofit/afranges.h (SCRIPT): Use it to export no-base ranges.
  828. 2015-09-04 Werner Lemberg <wl@gnu.org>
  829. [autofit] Redesign code ranges (1/2).
  830. This patch introduces auxiliary code ranges that identify no-base
  831. characters; they refer to glyphs of a script that should be hinted
  832. without alignments to blue zones (mostly diacritics).
  833. It also splits off ranges for fallback scripts that handle subscript
  834. and superscript characters not covered by OpenType features. For
  835. example, this greatly helps improve the hinting of various phonetic
  836. alphabets, which contain a large amount characters that look like
  837. superscript glyphs.
  838. Finally, code ranges are updated to Unicode 8.0, and enclosed
  839. characters are removed in general since they normally look better if
  840. they stay unhinted.
  841. * src/autofit/afranges.c (af_latn_uniranges): Updated to Unicode
  842. 8.0.
  843. Split off superscript-like and subscript-like glyphs into...
  844. (af_latb_uniranges, af_latp_uniranges): ... these two new arrays.
  845. (af_xxxx_nobase_uniranges): New arrays that hold no-base characters
  846. of the corresponding character ranges.
  847. 2015-09-03 Werner Lemberg <wl@gnu.org>
  848. [autofit] Pass glyph index to hinting function.
  849. No functionality change yet.
  850. * src/autofit/aftypes.h (AF_WritingSystem_ApplyHintsFunc): Pass
  851. glyph index.
  852. * src/autofit/afcjk.c, src/autofit/afcjk.h (af_cjk_hints_apply),
  853. src/autofit/afdummy.c (af_dummy_hints_apply), src/autofit/afindic.c
  854. (af_indic_hints_apply), src/autofit/aflatin.c
  855. (af_latin_hints_apply), src/autofit/aflatin2.c
  856. (af_latin2_hints_apply), src/autofit/afloader.c (af_loader_load_g):
  857. Updated.
  858. 2015-08-30 Werner Lemberg <wl@gnu.org>
  859. [autofit] Code clean-up.
  860. * src/autofit/afglobal.h (AF_STYLE_MASK): New macro.
  861. (AF_STYLE_UNASSIGNED): Use AF_STYLE_MASK for definition.
  862. * src/autofit/afglobal.c (af_face_globals_compute_style_coverage):
  863. Updated.
  864. 2015-08-30 Werner Lemberg <wl@gnu.org>
  865. [autofit] Make glyph style array use 16bit values.
  866. * include/freetype/ftautoh.h (FT_Prop_GlyphToScriptMap): Use
  867. `FT_UShort' for `map' field.
  868. * src/autofit/afglobal.c (af_face_globals_compute_style_coverage,
  869. af_face_globals_new), src/autofit/hbshim.c, src/autofit/hbshim.h
  870. (af_get_coverage): Use FT_UShort for `glyph_styles' array.
  871. * src/autofit/afglobal.h (AF_STYLE_UNASSIGNED, AF_DIGIT): Extend to
  872. 16 bits.
  873. (AF_FaceGlobalsRec): Use `FT_UShort' for `glyph_styles' field.
  874. 2015-08-26 Werner Lemberg <wl@gnu.org>
  875. * builds/unix/configure.raw: Need harfbuzz >= 0.9.21 (#45828).
  876. 2015-08-25 Werner Lemberg <wl@gnu.org>
  877. [base] Improve kerning tracing and documentation.
  878. * src/base/ftobjs.c (FT_Get_Kerning): Emit tracing message if
  879. scaled-down kerning values differ.
  880. 2015-08-18 Werner Lemberg <wl@gnu.org>
  881. [raster] Remove last remnants of `raster5' driver.
  882. * src/raster/ftrend1.h (ft_raster5_renderer_class): Removed.
  883. * src/raster/rastpic.c, src/raster/rastpic.h
  884. (ft_raster5_renderer_class_pic_init,
  885. ft_raster5_renderer_class_pic_free): Removed.
  886. 2015-08-17 Alexei Podtelezhnikov <apodtele@gmail.com>
  887. [base] Improve emboldener (#45596).
  888. * src/base/ftoutln.c (FT_Outline_EmboldenXY): Correct displacement
  889. of zero-lenght segments.
  890. 2015-08-16 Alexei Podtelezhnikov <apodtele@gmail.com>
  891. [base] Reoptimize arithmetic.
  892. * src/base/ftcalc.c (FT_MulDiv, FT_MulFix) [!FT_LONG64]: Remove
  893. special cases that slow down the general use.
  894. 2015-08-15 pazer <ibemad@gmail.com>
  895. Fix C++ compilation (#45762).
  896. * src/base/ftstroke.c (ft_outline_glyph_class): Use
  897. FT_CALLBACK_TABLE.
  898. 2015-08-14 Alexei Podtelezhnikov <apodtele@gmail.com>
  899. [truetype] Clean up.
  900. * src/truetype/ttgload.c (TT_Process_Composite_Component): Use
  901. `FT_Outline_Transform' and `FT_Outline_Translate'.
  902. (translate_array): Dropped.
  903. 2015-08-14 Andreas Enge <andreas.enge@inria.fr>
  904. * builds/unix/detect.mk (CONFIG_SHELL): Don't handle it (#44261).
  905. 2015-08-13 Werner Lemberg <wl@gnu.org>
  906. [truetype] Introduce named instance access to GX fonts.
  907. For functions querying a face, bits 16-30 of the face index can hold
  908. the named instance index if we have a GX font. The indices start
  909. with value 1; value 0 indicates font access without GX variation
  910. data.
  911. * include/freetype/freetype.h (FT_FaceRec): Update documentation.
  912. * include/freetype/internal/sfnt.h: Ditto.
  913. * src/sfnt/sfobjs.c (sfnt_init_face)
  914. [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Get number of named instances and
  915. do argument checks.
  916. (sfnt_load_face): Updated.
  917. * src/truetype/ttobjs.c (tt_face_init)
  918. [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Use named instance, overwriting
  919. the style name.
  920. * src/base/ftobjs.c (open_face_from_buffer,
  921. open_face_PS_from_sfnt_stream): Updated.
  922. * src/bdf/bdfdrivr.c (BDF_Face_Init): Updated.
  923. * src/cff/cffload.c (cff_font_load): Updated.
  924. * src/cff/cffobjs.c (cff_face_init): Make function exit early for
  925. pure CFF fonts if `font_index < 0'.
  926. Updated.
  927. * src/cid/cidobjs.c (cid_face_init): Updated.
  928. * src/pcf/pcfdrivr.c (PCF_Face_Init): Updated.
  929. * src/pfr/pfrobjs.c (pfr_face_init): Updated.
  930. * src/type1/t1objs.c (T1_Face_Init): Updated.
  931. * src/type42/t42objs.c (T42_Face_Init): Updated.
  932. * src/winfonts/winfnt.c (fnt_face_get_dll_font, FNT_Face_Init):
  933. Updated.
  934. * docs/CHANGES: Updated.
  935. 2015-08-12 Alexei Podtelezhnikov <apodtele@gmail.com>
  936. [type1,cff,cid] Streamline font matrix application.
  937. * src/type1/t1gload.c (T1_Load_Glyph): Directly modify advances only
  938. if font matrix is not trivial.
  939. * src/cff/cffgload.c (cff_slot_load): Ditto.
  940. * sff/cid/cidgload.c (cid_slot_load_glyph): Ditto for advances and the
  941. entire outline.
  942. 2015-08-11 Werner Lemberg <wl@gnu.org>
  943. [builds/unix] Minor.
  944. * builds/unix/configure.raw:
  945. s/lib{priv,staticconf}/libs{priv,staticconf}/ for orthogonality with
  946. similarly named uppercase variables.
  947. 2015-08-10 Alexei Podtelezhnikov <apodtele@gmail.com>
  948. [type1,cid,type42] Minor improvements.
  949. * src/type1/t1load.c (t1_parse_font_matrix): Scale units per EM only
  950. when necessary. Refresh comments.
  951. * src/cid/cidload.c (cid_parse_font_matrix): Ditto.
  952. * src/type42/t42parse.c (t42_parse_font_matrix): Refresh comments.
  953. 2015-08-08 Werner Lemberg <wl@gnu.org>
  954. [type42] Fix glyph access.
  955. This is a severe bug: We've missed one level of indirection, as
  956. described in the Type 42 specification. As a result, ftview
  957. sometimes showed incorrect glyphs for given glyph names, and even
  958. displayed `error 0x0006' (invalid argument!) in case the number of
  959. glyph indices differed between the Type 42 font and the embedded
  960. TTF.
  961. Apparently, noone ever noticed it; this shows how much Type 42 fonts
  962. are in use...
  963. * src/type42/t42objs.c (T42_GlyphSlot_Load): Map Type 42 glyph index
  964. to embedded TTF's glyph index.
  965. 2015-08-08 Werner Lemberg <wl@gnu.org>
  966. [type42] Minor clean-up.
  967. * src/type42/t42parse.c (t42_parse_font_matrix): Remove unused
  968. variable.
  969. 2015-08-06 Alexei Podtelezhnikov <apodtele@gmail.com>
  970. [type42] Parse FontMatrix according to specifications.
  971. * src/type42/t42parse.c (t42_parse_font_matrix): Type 42 FontMatrix
  972. does not need scaling by 1000. Units_per_EM are taken from the
  973. embedded TrueType.
  974. 2015-08-06 Werner Lemberg <wl@gnu.org>
  975. [autofit] Improve Arabic hinting.
  976. Problem reported by Titus Nemeth <tn@tntypography.eu> (by using
  977. ttfautohint).
  978. * src/autofit/afblue.dat: Add neutral blue zone for the tatweel
  979. character.
  980. * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
  981. 2015-08-05 Alexei Podtelezhnikov <apodtele@gmail.com>
  982. [truetype] Clean up types.
  983. * src/truetype/ttobjs.c (TT_Size): Move declaration from here.
  984. * include/freetype/internal/tttypes.h (TT_Size): ... to here.
  985. (TT_LoaderRec): Switch to appropriate types for `face' and `size'.
  986. * src/truetype/ttgload.c: Remove corresponding type casts.
  987. * src/truetype/ttsubpix.c: Ditto.
  988. 2015-08-05 Werner Lemberg <wl@gnu.org>
  989. [autofit] Improve recognition of flat vs. rounded segments.
  990. Lower the flatness threshold from upem/8 to upem/14, making the
  991. auto-hinter accept shorter elements.
  992. Synchronize flat/round stem selection algorithm with blue zone code.
  993. * src/autofit/aflatin.c (FLAT_THRESHOLD): New macro.
  994. (af_latin_metrics_init_blues): Use it.
  995. (af_latin_hints_compute_segments): Collect information on maximum
  996. and minimum coordinates of `on' points; use this to add a constraint
  997. for the flat/round decision similar to
  998. `af_latin_metrics_init_blues'.
  999. 2015-08-04 Werner Lemberg <wl@gnu.org>
  1000. Another left-shift bug (#45681).
  1001. * src/base/ftobjs.c (IsMacBinary): Only accept positive values for
  1002. `dlen'.
  1003. 2015-08-03 Alexei Podtelezhnikov <apodtele@gmail.com>
  1004. [base] Fix `ft_corner_orientation'.
  1005. Remove casting from `FT_Long' to `FT_Int' that might change the sign
  1006. of the return value and make it faster too.
  1007. * src/base/ftcalc.c (ft_corner_orientation): On 32-bit systems, stay
  1008. with 32-bit arithmetic when safe. Use plain math on 64-bit systems.
  1009. * src/pshinter/pshalgo.c: Remove old unused code.
  1010. 2015-08-03 Werner Lemberg <wl@gnu.org>
  1011. * src/truetype/ttgload.c (load_truetype_glyph)
  1012. [TT_CONFIG_OPTION_GX_VAR_SUPPORT]: Fix crash for composite glyphs
  1013. having a depth greater than 1.
  1014. 2015-08-03 Werner Lemberg <wl@gnu.org>
  1015. Fix typo in clang bug from 2015-07-31 (#45678).
  1016. * src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Fix inequality.
  1017. 2015-08-02 Werner Lemberg <wl@gnu.org>
  1018. * CMakeLists.txt: Improve shared library support.
  1019. Based on a patch from John Cary <cary@txcorp.com>.
  1020. 2015-08-02 Werner Lemberg <wl@gnu.org>
  1021. * builds/unix/freetype-config.in (enable_shared): Remove. Unused.
  1022. 2015-08-02 Werner Lemberg <wl@gnu.org>
  1023. Fix more invalid left-shifts.
  1024. * src/pfr/pfrgload.c (pfr_glyph_load_compound): Use multiplication,
  1025. not left-shift.
  1026. * src/truetype/ttgxvar.c (ft_var_load_avar, ft_var_load_gvar,
  1027. tt_face_vary_cvt, TT_Vary_Apply_Glyph_Deltas): Use multiplication,
  1028. not left-shift.
  1029. 2015-07-31 Werner Lemberg <wl@gnu.org>
  1030. Fix some bugs found by clang's `-fsanitize=undefined' (#45661).
  1031. * src/base/ftrfork.c (FT_Raccess_Get_HeaderInfo): Only accept
  1032. positive values from header.
  1033. Check overflow.
  1034. * src/base/ftoutln.c (SCALED): Correctly handle left-shift of
  1035. negative values.
  1036. * src/bdf/bdf.h (_bdf_glyph_modified, _bdf_set_glyph_modified,
  1037. _bdf_clear_glyph_modified): Use unsigned long constant.
  1038. * src/bdf/bdfdrivr.c (BDF_Size_Select, BDF_Glyph_Load): Don't
  1039. left-shift values that can be negative.
  1040. * src/pcf/pcfdrivr.c (PCF_Size_Select, PCF_Glyph_Load): Don't
  1041. left-shift values that can be negative.
  1042. * src/raster/ftraster.c (SCALED): Correctly handle left-shift of
  1043. negative values.
  1044. * src/sfnt/ttsbit.c (tt_face_load_strike_metrics): Don't left-shift
  1045. values that can be negative.
  1046. * src/truetype/ttgload.c (TT_Load_Composite_Glyph,
  1047. compute_glyph_metrics, load_sbit_image): Don't left-shift values
  1048. that can be negative.
  1049. 2015-07-31 Werner Lemberg <wl@gnu.org>
  1050. Define FT_LONG_MAX.
  1051. * include/freetype/config/ftstdlib.h (FT_LONG_MAX): New macro.
  1052. * src/cff/cf2arrst.c (cf2_arrstack_setNumElements): Use it.
  1053. 2015-07-28 Alexei Podtelezhnikov <apodtele@gmail.com>
  1054. * src/base/ftcalc.c (FT_Vector_NormLen): Clarify.
  1055. 2015-07-27 Alexei Podtelezhnikov <apodtele@gmail.com>
  1056. * src/base/ftcalc.c (FT_Vector_NormLen): Explicate type conversions.
  1057. 2015-07-26 Matthias Clasen <matthias.clasen@gmail.com>
  1058. [cff] Don't use `hmtx' table for LSB (#45520).
  1059. * src/cff/cffgload.c (cff_slot_load): Use `htmx' table for advance
  1060. width only. Bug introduced 2015-04-10.
  1061. 2015-07-09 Werner Lemberg <wl@gnu.org>
  1062. Better support of user-supplied C++ namespaces.
  1063. See
  1064. http://lists.nongnu.org/archive/html/freetype-devel/2015-07/msg00008.html
  1065. for a rationale.
  1066. * src/autofit/afpic.h, src/base/basepic.h, src/cff/cffpic.h,
  1067. src/pshinter/pshpic.h, src/psnames/pspic.h, src/raster/rastpic.h,
  1068. src/sfnt/sfntpic.h, src/smooth/ftspic.h, src/truetype/ttpic.h
  1069. (FT_BEGIN_HEADER, FT_END_HEADER): Move macro calls to not enclose
  1070. header files that contain FT_{BEGIN,END}_HEADER macros by
  1071. themselves.
  1072. * src/autofit/aftypes.h [FT_DEBUG_AUTOFIT]: Include
  1073. FT_CONFIG_STANDARD_LIBRARY_H earlier.
  1074. * src/truetype/ttpic.h: Include FT_INTERNL_PIC_H.
  1075. 2015-07-07 Werner Lemberg <wl@gnu.org>
  1076. [sfnt] Make `tt_face_get_name' member of the SFNT interface.
  1077. * include/freetype/internal/sfnt.h (TT_Get_Name_Func): New
  1078. prototype.
  1079. (SFNT_Interface, FT_DEFINE_SFNT_INTERFACE): New member `get_name'.
  1080. * src/sfnt/sfdriver.c (sfnt_interface): Updated.
  1081. * src/sfnt/sfobjs.c (tt_face_get_name): Tag it with `LOCAL_DEF'.
  1082. * src/sfnt/sfobjs.h: Add prototype for it.
  1083. 2015-06-30 Werner Lemberg <wl@gnu.org>
  1084. Fix some clang compiler warnings.
  1085. * src/base/ftoutln.c (FT_Outline_EmboldenXY), src/cff/cf2intrp.c
  1086. (cf2_interpT2CharString), src/truetype/ttgload.c
  1087. (load_truetype_glyph), src/truetype/ttgxvar.c (tt_handle_deltas),
  1088. src/truetype/ttinterp.c (Ins_INSTCTRL): Fix signedness issues.
  1089. 2015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
  1090. [truetype] Speed up bytecode interpreter.
  1091. * src/truetype/ttinterp.c (Normalize): Use `FT_Vector_NormLen'.
  1092. 2015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
  1093. [base] Speed up emboldening.
  1094. * src/base/ftoutln.c (FT_Outline_EmboldenXY): Use
  1095. `FT_Vector_NormLen'.
  1096. 2015-06-29 Alexei Podtelezhnikov <apodtele@gmail.com>
  1097. [base] Implement fast vector normalization.
  1098. The function uses Newton's iterations instead of dividing vector
  1099. components by its length, which needs a square root. This is,
  1100. literally, a bit less accurate but a lot faster.
  1101. * src/base/ftcalc.c (FT_Vector_NormLen): New function.
  1102. 2015-06-28 Werner Lemberg <wl@gnu.org>
  1103. * CMakeLists.txt: Always create `ftconfig.h'.
  1104. For non-UNIX builds, the file stays unmodified. However, it's
  1105. better to have the main configuration files at the same place
  1106. regardless of the OS.
  1107. 2015-06-28 Werner Lemberg <wl@gnu.org>
  1108. * CMakeLists.txt: Improve MSVC support (#43737).
  1109. 2015-06-28 Werner Lemberg <wl@gnu.org>
  1110. [cmake] Check for libraries and create `ftoption.h'.
  1111. * builds/FindHarfBuzz.cmake: New file, taken from
  1112. https://trac.webkit.org/browser/trunk/Source/cmake/FindHarfBuzz.cmake
  1113. * CMakeLists.Txt: Add path to local cmake modules.
  1114. Find dependencies for zlib, bzip2, libpng, and harfbuzz.
  1115. Create `ftoption.h' file.
  1116. Set up include and linker stuff for libraries.
  1117. 2015-06-28 Werner Lemberg <wl@gnu.org>
  1118. * CMakeLists.txt: Fix creation of `ftconfig.h'.
  1119. Check for UNIX header files using `check_include_file'.
  1120. Set up correct header include directories.
  1121. 2015-06-28 Werner Lemberg <wl@gnu.org>
  1122. * CMakeLists.txt: Disallow in-source builds.
  1123. 2015-06-27 Werner Lemberg <wl@gnu.org>
  1124. * src/tools/docmaker/utils.py (check_output): Add missing `\n'.
  1125. 2015-06-26 Werner Lemberg <wl@gnu.org>
  1126. * CMakeLists.txt: Select platform-dependent `ftdebug.c'.
  1127. 2015-06-25 Werner Lemberg <wl@gnu.org>
  1128. * CMakeLists.txt: Use cmake functions for generating `ftconfig.h'.
  1129. Additionally, do this for UNIX only.
  1130. 2015-06-25 Werner Lemberg <wl@gnu.org>
  1131. * CMakeLists.txt (BASE_SRCS): Use `ftbase.c' and `psnames.c'.
  1132. 2015-06-25 Werner Lemberg <wl@gnu.org>
  1133. Another adjustment to header locations.
  1134. This change is a result of a discussion thread on freetype-devel
  1135. http://lists.nongnu.org/archive/html/freetype-devel/2015-06/msg00041.html
  1136. Re-introduce the `freetype2' subdirectory for all FreeType header
  1137. files after installation, and rename the `freetype2' subdirectory in
  1138. the git repository to `freetype'.
  1139. * include/freetype2: Renamed to...
  1140. * include/freetype: This.
  1141. * CMakeLists.txt (PUBLIC_HEADERS, PUBLIC_CONFIG_HEADERS,
  1142. PRIVATE_HEADERS): Updated.
  1143. Update creation of `ftconfig.h'.
  1144. Install generated `ftconfig.h'.
  1145. * Jamfile (HDRMACRO, RefDoc), autogen.sh: Updated.
  1146. * builds/amiga/include/config/ftconfig.h, builds/freetype.mk
  1147. (PUBLIC_DIR), builds/symbian/bld.inf, builds/toplevel.mk (work),
  1148. builds/unix/freetype2.in: Updated.
  1149. * builds/unix/freetype-config.in: Updated.
  1150. * builds/unix/configure.raw: Don't check for `rmdir'.
  1151. * builds/unix/unix-def.in (DELDIR): Use `rm -rf', which is portable
  1152. according to the autoconf info manual.
  1153. * builds/unix/install.mk (install, uninstall,
  1154. distclean_project_unix): Update and simplify.
  1155. * builds/wince/*, builds/windows/*: Updated.
  1156. * devel/ft2build.h, include/ft2build.h: Updated.
  1157. * include/freetype2/config/ftheader.h,
  1158. include/freetype2/internal/ftserv.h,
  1159. include/freetype2/internal/internal.h: Update all header file
  1160. macros.
  1161. * src/tools/chktrcmp.py (TRACE_DEF_FILES): Updated.
  1162. * docs/*: Updated.
  1163. 2015-06-24 Alexei Podtelezhnikov <apodtele@gmail.com>
  1164. * src/bdf/bdflib.c (_bdf_parse_start): Disallow 0 bpp.
  1165. 2015-06-24 Alexei Podtelezhnikov <apodtele@gmail.com>
  1166. * src/bdf/bdflib.c (_bdf_parse_start): Simplify bpp parsing.
  1167. 2015-06-23 Werner Lemberg <wl@gnu.org>
  1168. s/TYPEOF/FT_TYPEOF/ (#45376).
  1169. * builds/unix/ftconfig.in, builds/vms/ftconfig.in,
  1170. include/freetype2/config/ftconfig.h,
  1171. include/freetype2/internal/ftobjs.h, src/autofit/afwarp.h: Do it.
  1172. 2015-06-22 Werner Lemberg <wl@gnu.org>
  1173. Fix Savannah bug #45097.
  1174. We no longer `pollute' the namespace of possible header file names;
  1175. instead we move `ft2build.h' up by one level so that it gets
  1176. installed in the default include directory (e.g.,
  1177. /usr/local/include). After this commit, only `ft2build.h' stays in
  1178. the compiler's include path.
  1179. No visible changes for the user who follows the standard FreeType
  1180. header inclusion rules.
  1181. * include/*: Move to ...
  1182. * include/freetype2/*: This directory, except `ft2build.h'.
  1183. * CMakeLists.txt (PUBLIC_HEADERS, PUBLIC_CONFIG_HEADERS,
  1184. PRIVATE_HEADERS), Jamfile (HDRMACRO, RefDoc), autogen.sh: Updated.
  1185. * builds/amiga/include/config/ftconfig.h, builds/freetype.mk
  1186. (PUBLIC_DIR), builds/symbian/bld.inf, builds/toplevel.mk (work),
  1187. builds/unix/install.mk (install, uninstall),
  1188. builds/unix/freetype2.in: Updated.
  1189. * builds/unix/freetype-config.in: Updated.
  1190. Emit -I directory only if it is not `/usr/include'.
  1191. * builds/wince/*, builds/windows/*: Updated.
  1192. * devel/ft2build.h, include/ft2build.h: Updated.
  1193. * include/freetype2/config/ftheader.h,
  1194. include/freetype2/internal/ftserv.h,
  1195. include/freetype2/internal/internal.h: Update all header file
  1196. macros.
  1197. * src/tools/chktrcmp.py (TRACE_DEF_FILES): Updated.
  1198. 2015-06-21 Werner Lemberg <wl@gnu.org>
  1199. Make Jam support work again.
  1200. This is just very basic stuff and just a little bit tested on
  1201. GNU/Linux only. I won't delve into this since I'm not a Jam user.
  1202. * Jamfile: Call `HDRMACRO' for `ftserv.h' also.
  1203. (DEFINES): Replace with...
  1204. (CCFLAGS): ... this.
  1205. * src/Jamfile: Don't call `HDRMACRO' for `internal.h'; this is
  1206. already handled in the top-level Jamfile.
  1207. * src/autofit/Jamfile (DEFINES): Replace with...
  1208. (CCFLAGS): ... this.
  1209. (_sources): Add missing files.
  1210. * src/cache/Jamfile: Don't call `HDRMACRO' for `ftcache.h'; it no
  1211. longer contains macro header definitions.
  1212. * src/base/Jamfile, src/cff/Jamfile, src/sfnt/Jamfile,
  1213. src/truetype/Jamfile (_sources): Add missing files.
  1214. 2015-06-16 Werner Lemberg <wl@gnu.org>
  1215. Fix Savannah bug #45326.
  1216. * src/sfnt/sfntpic.h (SFNT_SERVICES_GET): Remove duplicate
  1217. definitions.
  1218. 2015-06-07 Werner Lemberg <wl@gnu.org>
  1219. * Version 2.6 released.
  1220. =======================
  1221. Tag sources with `VER-2-6'.
  1222. * docs/VERSION.DLL: Update documentation and bump version number to
  1223. 2.6.
  1224. * README, Jamfile (RefDoc), builds/windows/vc2005/freetype.vcproj,
  1225. builds/windows/vc2005/index.html,
  1226. builds/windows/vc2008/freetype.vcproj,
  1227. builds/windows/vc2008/index.html,
  1228. builds/windows/vc2010/freetype.vcxproj,
  1229. builds/windows/vc2010/index.html,
  1230. builds/windows/visualc/freetype.dsp,
  1231. builds/windows/visualc/freetype.vcproj,
  1232. builds/windows/visualc/index.html,
  1233. builds/windows/visualce/freetype.dsp,
  1234. builds/windows/visualce/freetype.vcproj,
  1235. builds/windows/visualce/index.html,
  1236. builds/wince/vc2005-ce/freetype.vcproj,
  1237. builds/wince/vc2005-ce/index.html,
  1238. builds/wince/vc2008-ce/freetype.vcproj,
  1239. builds/wince/vc2008-ce/index.html: s/2.5.5/2.6/, s/255/26/.
  1240. * include/freetype/freetype.h (FREETYPE_MINOR): Set to 6.
  1241. (FREETYPE_PATCH): Set to 0.
  1242. * builds/unix/configure.raw (version_info): Set to 18:0:12.
  1243. * CMakeLists.txt (VERSION_MINOR): Set to 6.
  1244. (VERSION_PATCH): Set to 0.
  1245. * src/autofit/afmodule.c [!FT_MAKE_OPTION_SINGLE_OBJECT]: Add
  1246. declarations for dumping functions.
  1247. * src/truetype/ttinterp.c (TT_New_Context): Pacify compiler.
  1248. * builds/toplevel.mk: Use `freetype.mk's code to compute the version
  1249. string.
  1250. Don't include a zero patch level in version string.
  1251. * builds/freetype.mk: Remove code for computing the version string.
  1252. 2015-06-06 Ashish Azad <ashish.azad@samsung.com>
  1253. Fix Savannah bug #45260.
  1254. * src/pfr/pfrdrivr.c (pfr_get_kerning): Fix typo.
  1255. 2015-06-03 Werner Lemberg <wl@gnu.org>
  1256. [truetype] Fix memory leak.
  1257. Problem reported by Grissiom <chaos.proton@gmail.com>; in
  1258. http://lists.nongnu.org/archive/html/freetype/2015-05/msg00013.html
  1259. there is an example code to trigger the bug.
  1260. * src/truetype/ttobjs.c (tt_size_init_bytecode): Free old `size'
  1261. data before allocating again. Bug most probably introduced four
  1262. years ago in version 2.4.3.
  1263. 2015-06-02 Werner Lemberg <wl@gnu.org>
  1264. [raster] Add more tracing.
  1265. * src/raster/ftraster.c (FT_TRACE7) [_STANDALONE_]: Define.
  1266. (Vertical_Sweep_Span, Vertical_Sweep_Drop, Horizontal_Sweep_Span,
  1267. Horizontal_Sweep_Drop, Render_Glyph): Add tracing calls.
  1268. 2015-06-01 Werner Lemberg <wl@gnu.org>
  1269. [truetype] While tracing opcodes, show code position and stack.
  1270. * src/truetype/ttinterp.c: Change all existing TRACE7 calls to
  1271. TRACE6.
  1272. (opcode_name): Add string lengths.
  1273. (TT_RunIns): Implement display of code position and stack.
  1274. 2015-05-31 Werner Lemberg <wl@gnu.org>
  1275. [truetype] In GX, make private point numbers work correctly.
  1276. This is completely missing in Apple's documentation: If a `gvar'
  1277. tuple uses private point numbers (this is, deltas are specified for
  1278. some points only), the uncovered points must be interpolated for
  1279. this tuple similar to the IUP bytecode instruction. Examples that
  1280. need this functionality are glyphs `Oslash' and `Q' in Skia.ttf.
  1281. * src/truetype/ttgxvar.c (tt_delta_shift, tt_delta_interpolate,
  1282. tt_handle_deltas): New functions.
  1283. (TT_Vary_Get_Glyph_Deltas): Renamed to...
  1284. (TT_Vary_Apply_Glyph_Deltas): ... this; it directly processes the
  1285. points and does no longer return an array of deltas.
  1286. Add tracing information.
  1287. Call `tt_handle_deltas' to interpolate missing deltas.
  1288. Also fix a minor memory leak in case of error.
  1289. * src/truetype/ttgxvar.h: Updated.
  1290. * src/truetype/ttgload.c (TT_Process_Simple_Glyph,
  1291. load_truetype_glyph): Updated.
  1292. 2015-05-31 Werner Lemberg <wl@gnu.org>
  1293. [truetype] In GX, make intermediate tuplets work at extrema.
  1294. * src/truetype/ttgxvar.c (ft_var_apply_tuple): Fix range condition.
  1295. 2015-05-31 Werner Lemberg <wl@gnu.org>
  1296. [truetype] Add tracing information to GX code.
  1297. * src/truetype/ttgxvar.c (ft_var_load_avar, ft_var_load_gvar,
  1298. ft_var_apply_tuple, TT_Get_MM_Var, TT_Set_MM_Blend,
  1299. TT_Set_Var_Design, tt_face_vary_cvt): Do it.
  1300. 2015-05-28 Werner Lemberg <wl@gnu.org>
  1301. * src/tools/apinames.c (names_dump): Fix invalid reference.
  1302. Problem reported by Guzman Mosqueda, Jose R
  1303. <jose.r.guzman.mosqueda@intel.com>.
  1304. 2015-05-24 Werner Lemberg <wl@gnu.org>
  1305. [truetype] Fix commit from 2015-05-22.
  1306. * src/truetype/ttgload.c, src/truetype/ttinterp.c: Guard new code
  1307. with `TT_CONFIG_OPTION_SUBPIXEL_HINTING'.
  1308. Problem reported by Nikolaus Waxweiler <madigens@gmail.com>.
  1309. 2015-05-23 Werner Lemberg <wl@gnu.org>
  1310. [truetype] Fix return values of GETINFO bytecode instruction.
  1311. * src/truetype/ttinterp.h (TT_ExecContextRec): New fields
  1312. `vertical_lcd' and `gray_cleartype'.
  1313. * src/truetype/ttgload.c (tt_loader_init): Initialize new fields.
  1314. Change `symmetrical smoothing' to TRUE, since FreeType produces
  1315. exactly this.
  1316. * src/truetype/ttinterp.c (Ins_GETINFO): Fix selector/return bit
  1317. values for symmetrical smoothing, namely 11/18.
  1318. Handle bits for vertical LCD subpixels (8/15) and Gray ClearType
  1319. (12/19).
  1320. 2015-05-23 Werner Lemberg <wl@gnu.org>
  1321. [truetype] Minor.
  1322. * src/truetype/ttinterp.h (TT_ExecContext):
  1323. s/subpixel/subpixel_hinting.
  1324. * src/truetype/ttgload.c, src/truetype/ttgload.h: Updated.
  1325. 2015-05-22 Werner Lemberg <wl@gnu.org>
  1326. [truetype] Support selector index 3 of the INSTCTRL instruction.
  1327. This flag activates `native ClearType hinting', disabling backwards
  1328. compatibility mode as described in Greg Hitchcocks whitepaper. In
  1329. other words, it enables unrestricted functionality of all TrueType
  1330. instructions in ClearType.
  1331. * src/truetype/ttgload.c (tt_get_metrics): Call `sph_set_tweaks'
  1332. unconditionally.
  1333. (tt_loader_init): Unset `ignore_x_mode' flag if bit 2 of
  1334. `GS.instruct_control' is active.
  1335. * src/truetype/ttinterp.c (Ins_INSTCTRL): Handle selector index 3.
  1336. (Ins_GETINFO): Updated.
  1337. * docs/CHANGES: Document it.
  1338. 2015-05-20 Werner Lemberg <wl@gnu.org>
  1339. [truetype] Minor.
  1340. * src/truetype/ttinterp.h (SetSuperRound): Fix type of `GridPeriod'
  1341. argument.
  1342. 2015-05-17 Werner Lemberg <wl@gnu.org>
  1343. [truetype] Fix loading of composite glyphs.
  1344. * src/truetype/ttgload.c (TT_Load_Composite_Glyph): If the
  1345. ARGS_ARE_XY_VALUES flag is not set, handle argument values as
  1346. unsigned. I trust `ttx' (which has exactly such code) that it does
  1347. the right thing here...
  1348. The reason that noone has ever noticed this bug is probably the fact
  1349. that point-aligned subglyphs are rare, as are subglyphs with a
  1350. number of points in the range [128;255], which is quite large (or
  1351. even in the range [32768;65535], which is extremely unlikely).
  1352. 2015-05-12 Chris Liddell <chris.liddell@artifex.com>
  1353. [cff] Make the `*curveto' operators more tolerant.
  1354. * src/cff/cf2intrp.c (cf2_interpT2CharString): The opcodes
  1355. `vvcurveto', `hhcurveto', `vhcurveto', and `hvcurveto' all iterate,
  1356. pulling values off the stack until the stack is exhausted.
  1357. Implicitly the stack must be a multiple (or for subtly different
  1358. behaviour) a multiple plus a specific number of extra values deep.
  1359. If that's not the case, enforce it (as the old code did).
  1360. 2015-05-12 Chris Liddell <chris.liddell@artifex.com>
  1361. [cff] fix incremental interface with new cff code.
  1362. * src/cff/cf2ft.c (cf2_getSeacComponent): When using the incremental
  1363. interface to retrieve glyph data for a SEAC, it be left to the
  1364. incremental interface callback to apply the encoding to raw
  1365. character index (as it was in the previous code).
  1366. 2015-04-29 Alexei Podtelezhnikov <apodtele@gmail.com>
  1367. [autofit] Speed up IUP.
  1368. * src/autofit/afhints.c (af_iup_interp): Separate trivial snapping to
  1369. the same position from true interpolation, use `scale' to reduce
  1370. divisions.
  1371. 2015-04-28 Werner Lemberg <wl@gnu.org>
  1372. [cff] Use `name' table for PS name if we have a SFNT-CFF.
  1373. This follows the OpenType 1.7 specification. See
  1374. http://tug.org/pipermail/tex-live/2015-April/036634.html
  1375. for a discussion.
  1376. * src/cff/cffdrivr.c (cff_get_ps_name): Use the `sfnt' service if we
  1377. have an SFNT.
  1378. 2015-04-27 Alexei Podtelezhnikov <apodtele@gmail.com>
  1379. [truetype] Speed up IUP.
  1380. * src/truetype/ttinterp.c (_iup_worker_interpolate): Separate trivial
  1381. snapping to the same position from true interpolation.
  1382. 2015-04-21 Werner Lemberg <wl@gnu.org>
  1383. [autofit] By default, enable warping code but switch off warping.
  1384. Suggested by Behdad.
  1385. * include/config/ftoption.h: Define AF_CONFIG_OPTION_USE_WARPER.
  1386. * src/autofit/afmodule.c (af_autofitter_init): Initialize `warping'
  1387. with `false'.
  1388. 2015-04-21 Werner Lemberg <wl@gnu.org>
  1389. * docs/CHANGES: Updated.
  1390. 2015-04-21 Werner Lemberg <wl@gnu.org>
  1391. [autofit] Introduce `warping' property.
  1392. This code replaces the debugging hook from the previous commit with
  1393. a better, more generic solution.
  1394. * include/ftautoh.h: Document it.
  1395. * src/autofit/afmodule.h (AF_ModuleRec)
  1396. [AF_CONFIG_OPTION_USE_WARPER]: Add `warping' field.
  1397. * src/autofit/afmodule.c (_af_debug_disable_warper): Remove.
  1398. (af_property_set, af_property_get, af_autofitter_init)
  1399. [AF_CONFIG_OPTION_USE_WARPER]: Handle `warping' option.
  1400. * src/autofit/afhints.h (AF_HINTS_DO_WARP): Remove use of the no
  1401. longer existing `_af_debug_disable_warper'.
  1402. * src/autofit/afcjk.c (af_cjk_hints_init), src/autofit/aflatin.c
  1403. (af_latin_hints_init), src/autofit/aflatin2.c (af_latin2_hints_init)
  1404. [AF_CONFIG_OPTION_USE_WARPER]: Add `AF_SCALER_FLAG_NO_WARPER' to the
  1405. scaler flags if warping is off.
  1406. * src/autofit/aftypes.h: Updated.
  1407. 2015-04-16 Werner Lemberg <wl@gnu.org>
  1408. [autofit] Add debugging hook to disable warper.
  1409. * src/autofit/afmodule.c (_af_debug_disable_warper)
  1410. [FT_DEBUG_AUTOFIT]: New global variable.
  1411. * src/autofit/aftypes.h: Updated.
  1412. (AF_SCALER_FLAG_NO_WARPER): New macro (not actively used yet).
  1413. * src/autofit/afhints.h (AF_HINTS_DO_WARP): New macro.
  1414. * src/autofi/aflatin.c (af_latin_hints_apply)
  1415. [AF_CONFIG_OPTION_USE_WARPER]: Use `AF_HINTS_DO_WARP' to control use
  1416. of warper.
  1417. * src/autofit/afcjk.c (af_cjk_hints_init, af_cjk_hints_apply)
  1418. [AF_CONFIG_OPTION_USE_WARPER]: Synchronize with `aflatin.c'.
  1419. * src/autofit/aflatin2.c (af_latin2_hints_apply)
  1420. [AF_CONFIG_OPTION_USE_WARPER]: Synchronize with `aflatin.c'.
  1421. 2015-04-10 Werner Lemberg <wl@gnu.org>
  1422. [cff] Update advance width handling to OpenType 1.7.
  1423. Problem reported by Behdad.
  1424. * src/cff/cffdrivr.c (cff_get_advances): Handle SFNT case
  1425. separately.
  1426. * src/cff/cffgload.c (cff_slot_load): Use advance width and side
  1427. bearing values from `hmtx' table if present.
  1428. 2015-04-03 Alexei Podtelezhnikov <apodtele@gmail.com>
  1429. * src/autofit/afhints.c (af_glyph_hints_reload): Use do-while loop.
  1430. 2015-04-02 Alexei Podtelezhnikov <apodtele@gmail.com>
  1431. * src/autofit/aflatin.c (af_latin_hint_edges): Reduce logic.
  1432. 2015-04-01 Alexei Podtelezhnikov <apodtele@gmail.com>
  1433. [autofit] Finish the thought.
  1434. * src/autofit/afhints.c (af_direction_compute): make sure the long arm
  1435. is never negative so that its `FT_ABS' is not necessary.
  1436. 2015-04-01 Werner Lemberg <wl@gnu.org>
  1437. [autofit] Call dumper functions for tracing.
  1438. * src/autofit/afcjk.c (af_cjk_hints_apply): Remove dead code.
  1439. * src/autofit/afhints.c (af_glyph_hints_dump_points): Minor
  1440. improvement.
  1441. * src/autofit/afmodule.c (af_autofitter_load_glyph): Implement it.
  1442. 2015-04-01 Werner Lemberg <wl@gnu.org>
  1443. [autofit] Make debugging stuff work again.
  1444. The interface to ftgrid was broken in the series of commits starting
  1445. with
  1446. [autofit] Allocate AF_Loader on the stack instead of AF_Module.
  1447. from 2015-01-14.
  1448. * src/autofit/afmodule.c (_af_debug_hints_rec) [FT_DEBUG_AUTOFIT]:
  1449. Use a global AF_GlyphHintsRec object for debugging.
  1450. (af_autofitter_done, af_autofitter_load_glyph): Updated.
  1451. * src/autofit/afloader.c (af_loader_init, af_loader_done): Updated.
  1452. 2015-04-01 Werner Lemberg <wl@gnu.org>
  1453. * src/autofit/afhints.c (af_glyph_hints_done): Fix minor thinko.
  1454. 2015-03-29 Werner Lemberg <wl@gnu.org>
  1455. [cff] Fix Savannah bug #44629.
  1456. * src/cff/cf2font.h (CF2_MAX_SUBR), src/cff/cffgload.h
  1457. (CFF_MAX_SUBRS_CALLS): Set to 16.
  1458. 2015-03-29 Werner Lemberg <wl@gnu.org>
  1459. [type1, truetype] Make the MM API more flexible w.r.t. `num_coords'.
  1460. This commit allows `num_coords' to be larger or smaller than the
  1461. number of available axes while selecting a design instance, either
  1462. ignoring excess data or using defaults if data is missing.
  1463. * src/truetype/ttgxvar.c (TT_Set_MM_Blend, TT_Set_Var_Design):
  1464. Implement it.
  1465. * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design,
  1466. T1_Set_Var_Design): Ditto.
  1467. 2015-03-29 Werner Lemberg <wl@gnu.org>
  1468. [type1] Minor.
  1469. * src/type1/t1load.c (T1_Set_MM_Blend, T1_Set_MM_Design): Use
  1470. FT_THROW.
  1471. (T1_Set_Var_Design): Use T1_MAX_MM_AXIS and FT_THROW.
  1472. 2015-03-27 Werner Lemberg <wl@gnu.org>
  1473. [cff] Trace charstring nesting levels.
  1474. * src/cff/cf2intrp.c (cf2_interpT2CharString) <cf2_cmdCALLGSUBR,
  1475. cf2_cmdCALLSUBR, cf2_cmdRETURN>: Implement it.
  1476. * src/cff/cffgload.c (cff_decoder_parse_charstrings)
  1477. <cff_op_callsubr, cff_op_callgsubr, cff_op_return>: Ditto.
  1478. 2015-03-21 Alexei Podtelezhnikov <apodtele@gmail.com>
  1479. [base] Optimize `FT_Angle_Diff'.
  1480. Under normal circumstances we are usually close to the desired range
  1481. of angle values, so that the remainder is not really necessary.
  1482. * src/base/fttrigon.c (FT_Angle_Diff): Use loops instead of remainder.
  1483. * src/autofit/aftypes.h (AF_ANGLE_DIFF): Ditto in the unused macro.
  1484. 2015-03-21 Werner Lemberg <wl@gnu.org>
  1485. [truetype] Improve `gvar' handling.
  1486. * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Correctly handle
  1487. single-element runs. Cf. glyph `Q' in Skia.ttf with weights larger
  1488. than the default.
  1489. 2015-03-20 Alexei Podtelezhnikov <apodtele@gmail.com>
  1490. * src/base/fttrigon.c (FT_Vector_Rotate): Minor refactoring.
  1491. 2015-03-17 Alexei Podtelezhnikov <apodtele@gmail.com>
  1492. Fix Savannah bug #44412 (part 2).
  1493. * src/base/fttrigon.c (FT_Sin, FT_Cos, FT_Tan): Call `FT_Vector_Unit'.
  1494. 2015-03-11 Werner Lemberg <wl@gnu.org>
  1495. [autofit] Add support for Arabic script.
  1496. Thanks to Titus Nemeth <tn@tntypography.eu> for guidance!
  1497. * src/autofit/afblue.dat: Add blue zone data for Arabic.
  1498. * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
  1499. * src/autofit/afscript.h: Add Arabic standard characters.
  1500. * src/autofit/afranges.c: Add Arabic data.
  1501. * src/autofit/afstyles.h: Add Arabic data.
  1502. * docs/CHANGES: Document it.
  1503. 2015-03-11 Werner Lemberg <wl@gnu.org>
  1504. Rename `svxf86nm.h' to `svfntfmt.h'; update related symbols.
  1505. * include/internal/ftserv.h (FT_SERVICE_XFREE86_NAME_H): Renamed
  1506. to...
  1507. (FT_SERVICE_FONT_FORMAT_H): This.
  1508. * include/internal/services/svfntfmt.h (FT_XF86_FORMAT_*): Renamed
  1509. to ...
  1510. (FT_FONT_FORMAT_*): This.
  1511. src/base/ftfntfmt.c, src/bdf/bdfdrivr.c, src/cff/cffdrivr.c,
  1512. src/cid/cidriver.c, src/pcf/pcfdrivr.c, src/pfr/pfrdrivr.c,
  1513. src/truetype/ttdriver.c, src/type1/t1driver.c,
  1514. src/type42/t42drivr.c, src/winfonts/winfnt.c: Updated.
  1515. 2015-03-11 Werner Lemberg <wl@gnu.org>
  1516. [base] Rename `FT_XFREE86_H' to `FT_FONT_FORMATS_H'.
  1517. * include/config/ftheader.h: Implement it.
  1518. * src/base/ftfntfmt.c, docs/CHANGES: Updated.
  1519. 2015-03-11 Werner Lemberg <wl@gnu.org>
  1520. [base] Rename `FT_Get_X11_Font_Format' to `FT_Get_Font_Format'.
  1521. * include/ftfntfmt.h, src/base/ftfntfmt.c: Implement it.
  1522. * docs/CHANGES: Updated.
  1523. 2015-03-11 Werner Lemberg <wl@gnu.org>
  1524. Fix automatic copyright updating.
  1525. * src/tools/update-copyright: Make scanning of `no-copyright'
  1526. actually work.
  1527. * src/tools/no-copyright: Don't include README in general.
  1528. 2015-03-11 Werner Lemberg <wl@gnu.org>
  1529. Rename `ftxf86.[ch]' to `ftfntfmt.[ch]'.
  1530. CMakeLists.txt, builds/amiga/makefile, builds/amiga/makefile.os4,
  1531. builds/amiga/smakefile, builds/mac/FreeType.m68k_cfm.make.txt,
  1532. builds/mac/FreeType.m68k_far.make.txt,
  1533. builds/mac/FreeType.ppc_carbon.make.txt,
  1534. builds/mac/FreeType.ppc_classic.make.txt, builds/symbian/bld.inf,
  1535. builds/symbian/freetype.mmp, builds/wince/vc2005-ce/freetype.vcproj,
  1536. builds/wince/vc2008-ce/freetype.vcproj,
  1537. builds/windows/vc2005/freetype.vcproj,
  1538. builds/windows/vc2008/freetype.vcproj,
  1539. builds/windows/vc2010/freetype.vcxproj,
  1540. builds/windows/vc2010/freetype.vcxproj.filters,
  1541. builds/windows/visualc/freetype.dsp,
  1542. builds/windows/visualc/freetype.vcproj,
  1543. builds/windows/visualce/freetype.dsp,
  1544. builds/windows/visualce/freetype.vcproj, docs/INSTALL.ANY,
  1545. include/config/ftheader.h, include/ftfntfmt.h, modules.cfg,
  1546. src/base/ftfntfmt.c, vms_make.com: Updated.
  1547. 2015-03-10 Alexei Podtelezhnikov <apodtele@gmail.com>
  1548. Fix Savannah bug #44412 (part 1).
  1549. * src/base/ftstroke.c (ft_stroker_inside): Handle near U-turns.
  1550. 2015-03-10 Werner Lemberg <wl@gnu.org>
  1551. [base] Rename `FT_Bitmap_New' to `FT_Bitmap_Init'.
  1552. * include/ftbitmap.h, src/base/ftbitmap.c: Implement it.
  1553. Update all callers.
  1554. * docs/CHANGES: Updated.
  1555. 2015-03-06 Werner Lemberg <wl@gnu.org>
  1556. * src/sfnt/ttload.c (tt_face_load_font_dir): Fix compiler warning.
  1557. Found by Alexei.
  1558. 2015-03-05 Alexei Podtelezhnikov <apodtele@gmail.com>
  1559. * src/base/ftstroke.c: Simplify.
  1560. 2015-03-04 Werner Lemberg <wl@gnu.org>
  1561. [truetype] Some fixes and code refactoring in `ttgxvar.c'.
  1562. * src/truetype/ttgxvar.c (ft_var_readpackedpoints): Fix return value
  1563. of `point_cnt' if two bytes are read.
  1564. Use a more vertical coding style.
  1565. (ft_var_readpackeddeltas): Use FT_UInt for `delta_cnt' parameter.
  1566. Use a more vertical coding style.
  1567. 2015-03-03 Werner Lemberg <wl@gnu.org>
  1568. [autofit] Fix Savannah bug #44241.
  1569. * src/autofit/aflatin.c (af_latin_metrics_init_blues): Reject glyphs
  1570. with less than 3 points.
  1571. 2015-03-02 Werner Lemberg <wl@gnu.org>
  1572. Simplify `TYPEOF' macro.
  1573. No need for two arguments.
  1574. * include/config/ftconfig.h, builds/unix/ftconfig.in,
  1575. builds/vms/ftconfig.h (TYPEOF): Updated.
  1576. * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
  1577. src/autofit/afwarp.h (AF_WARPER_FLOOR): Updated.
  1578. 2015-03-01 Werner Lemberg <wl@gnu.org>
  1579. Various compiler warning fixes for `make multi'.
  1580. * src/autofit/afcjk.c (af_cjk_hints_compute_blue_edges),
  1581. src/autofit/aflatin.c (af_latin_hint_compute_blue_edges,
  1582. af_latin_hint_edges), src/autofit/aflatin2.c
  1583. (af_latin2_hints_compute_blue_edges, af_latin2_hint_edges): Declare
  1584. as `static'.
  1585. * src/cache/ftccmap.c (FTC_CMAP_QUERY_HASH, FTC_CMAP_NODE_HASH):
  1586. Removed. Unused.
  1587. * src/cache/ftcimage.c: Include FT_INTERNAL_OBJECTS_H.
  1588. * src/cache/ftcmanag.c (FTC_LRU_GET_MANAGER): Removed. Unused.
  1589. * src/cff/cf2intrp.c: Include `cf2intrp.h'.
  1590. * src/cff/cffdrivr.c (PAIR_TAG): Removed. Unused.
  1591. * src/gzip/ftgzip.c (NO_DUMMY_DECL): Removed. Unused.
  1592. * src/psaux/afmparse.c (afm_parser_read_int): Declare as `static'.
  1593. * src/pshinter/pshalgo.c (STRONGER, PSH_ZONE_MIN, PSH_ZONE_MAX):
  1594. Removed. Unused.
  1595. * src/raster/ftraster.c (Render_Glyph): Declare as `static'.
  1596. * src/sfnt/ttpost.c (load_format_20): Fix signedness warning.
  1597. * src/truetype/ttdriver.c (PAIR_TAG): Removed. Unused.
  1598. * src/truetype/ttsubpix.c (is_member_of_family_class,
  1599. is_member_of_style_class): Declare as `static'.
  1600. * src/type1/t1gload.c (T1_Parse_Glyph_And_Get_Char_String): Declare
  1601. as `static'.
  1602. * src/type1/t1load.c (mm_axis_unmap, mm_weights_unmap): Declare as
  1603. `static'.
  1604. (T1_FIELD_COUNT): Removed. Unused.
  1605. * src/type1/t1parse.h (T1_Done_Table): Removed. Unused.
  1606. * src/type42/t42parse.c (T1_Done_Table): Removed. Unused.
  1607. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1608. [psaux] Signedness fixes.
  1609. * include/internal/psaux.h, src/psaux/afmparse.c,
  1610. src/psaux/afmparse.h, src/psaux/psconv.c, src/psaux/psobjs.c,
  1611. src/psaux/t1cmap.c, src/psaux/t1decode.c: Apply.
  1612. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1613. [otvalid] Signedness fixes.
  1614. * src/otvalid/otvcommn.c, src/otvalid/otvgdef.c,
  1615. src/otvalid/otvgpos.c, src/otvalid/otvgsub.c, src/otvalid/otvmath.c:
  1616. Apply.
  1617. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1618. * src/bzip2/ftbzip2.c (ft_bzip2_alloc): Signedness fix.
  1619. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1620. [lzw] Signedness fixes.
  1621. * src/lzw/ftzopen.c, src/lzw/ftzopen.h: Apply.
  1622. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1623. [gxvalid] Signedness fixes.
  1624. * src/gxvalid/gxvbsln.c, src/gxvalid/gxvcommn.c,
  1625. src/gxvalid/gxvcommn.h, src/gxvalid/gxvjust.c,
  1626. src/gxvalid/gxvkern.c, src/gxvalid/gxvlcar.c, src/gxvalid/gxvmort.c,
  1627. src/gxvalid/gxvmort1.c, src/gxvalid/gxvmort2.c,
  1628. src/gxvalid/gxvmorx.c, src/gxvalid/gxvmorx1.c,
  1629. src/gxvalid/gxvmorx2.c, src/gxvalid/gxvopbd.c,
  1630. src/gxvalid/gxvprop.c, src/gxvalid/gxvtrak.c: Apply.
  1631. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1632. [cache] Signedness fixes.
  1633. * src/cache/ftcbasic.c, src/cache/ftccmap.c, src/cache/ftcimage.c,
  1634. src/cache/ftcmanag.c, src/cache/ftcsbits.c: Apply.
  1635. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1636. Change dimension fields in `FTC_ImageTypeRec' to unsigned type.
  1637. This doesn't break ABI.
  1638. * include/ftcache.h (FTC_ImageTypeRec): Use unsigned types for
  1639. `width' and `height'.
  1640. * docs/CHANGES: Document it.
  1641. 2015-02-25 Werner Lemberg <wl@gnu.org>
  1642. [cache] Don't use `labs'.
  1643. This is the only place in FreeType where this function was used.
  1644. * include/config/ftstdlib.h (ft_labs): Remove.
  1645. * src/cache/ftcimage.c (ftc_inode_weight): Replace `ft_labs' with
  1646. `FT_ABS'.
  1647. 2015-02-23 Werner Lemberg <wl@gnu.org>
  1648. [cache] Replace `FT_PtrDist' with `FT_Offset'.
  1649. * src/cache/ftccache.h (FTC_NodeRec): `FT_Offset' (a.k.a. `size_t')
  1650. is a better choice for `hash' to hold a pointer than `FT_PtrDist'
  1651. (a.k.a. `ptrdiff_t'), especially since the latter is signed,
  1652. causing zillions of signedness warnings. [Note that `hash' was of
  1653. type `FT_UInt32' before the change to `FT_PtrDist'.]
  1654. Update all users.
  1655. * src/cache/ftcbasic.c, src/cache/ftccache.c, src/cache/ftccmap.c,
  1656. src/cache/ftcglyph.c, src/cache/ftcglyph.h: Updated.
  1657. 2015-02-23 Werner Lemberg <wl@gnu.org>
  1658. [smooth, raster] Re-enable standalone compilation.
  1659. * src/raster/ftraster.c (FT_RENDER_POOL_SIZE, FT_MAX)
  1660. [_STANDALONE_]: Define macros.
  1661. * src/smooth/ftgrays.c (FT_RENDER_POOL_SIZE, FT_MAX, FT_ABS,
  1662. FT_HYPOT) [_STANDALONE_]: Define macros.
  1663. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1664. [smooth] Signedness fixes.
  1665. * src/smooth/ftgrays.c, src/smooth/ftsmooth.c: Apply.
  1666. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1667. * src/raster/ftraster.c: Use the file's typedefs everywhere.
  1668. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1669. * src/sfnt/ttpost.c (load_format_20): Fix error tracing message.
  1670. Bug introduced 6 commits earlier.
  1671. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1672. [pshinter] Fix thinko.
  1673. * src/pshinter/pshalgo.c (psh_glyph_find_strong_points): Correctly
  1674. check `count'.
  1675. Bug introduced two commits earlier.
  1676. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1677. [raster] Signedness fixes.
  1678. * src/raster/ftraster.c, src/raster/ftrend1.c: Apply.
  1679. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1680. [pshinter] Signedness fixes.
  1681. * src/pshinter/pshalgo.c, src/pshinter/pshglob.c,
  1682. src/pshinter/pshrec.c: Apply.
  1683. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1684. [pshinter] Use macros for (unsigned) flags, not enumerations.
  1685. * src/pshinter/pshalgo.h (PSH_Hint_Flags): Replace with macros.
  1686. Updated.
  1687. * src/pshinter/pshrec.h (PS_Hint_Flags): Replace with macros.
  1688. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1689. * src/pshinter/pshrec.c: Simplify.
  1690. (ps_hints_open, ps_hints_stem): Remove switch statement.
  1691. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1692. [sfnt] Signedness fixes.
  1693. * src/sfnt/pngshim.c, src/sfnt/sfobjs.c, src/sfnt/ttcmap.c,
  1694. src/sfnt/ttkern.c, src/sfnt/ttload.c, src/sfnt/ttpost.c,
  1695. src/sfnt/ttsbit.c: Apply.
  1696. * src/sfnt/sfdriver.c: Apply.
  1697. (sfnt_get_ps_name): Simplify.
  1698. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1699. [bdf] Signedness fixes.
  1700. * src/bdf/bdf.h, src/bdf/bdfdrivr.c, src/bdf/bdfdrivr.h,
  1701. src/bdf/bdflib.c: Apply.
  1702. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1703. * src/bdf/bdflib.c (_bdf_atous): New function.
  1704. (_bdf_parse_glyphs, _bdf_parse_start): Use it.
  1705. 2015-02-22 Werner Lemberg <wl@gnu.org>
  1706. [pcf] Signedness fixes.
  1707. * src/pcf/pcf.h, src/pcf/pcfdrivr.c: Apply.
  1708. * src/pcf/pcfread.c: Apply.
  1709. (pcf_get_encodings): Ignore invalid negative encoding offsets.
  1710. 2015-02-21 Werner Lemberg <wl@gnu.org>
  1711. * src/winfonts/winfnt.c: Signedness fixes.
  1712. 2015-02-21 Werner Lemberg <wl@gnu.org>
  1713. [type42] Signedness fixes.
  1714. * src/type42/t42parse.c, src/type42/t42parse.h,
  1715. src/type42/t42types.h: Apply.
  1716. 2015-02-21 Werner Lemberg <wl@gnu.org>
  1717. [pfr] Signedness fixes.
  1718. * src/pfr/pfrdrivr.c, src/pfr/pfrgload.c, src/pfr/pfrload.c,
  1719. src/pfr/pfrload.h, src/pfr/pfrobjs.c, src/pfr/pfrsbit.c,
  1720. src/pfr/pfrtypes.h: Apply.
  1721. 2015-02-21 Werner Lemberg <wl@gnu.org>
  1722. [cff] Minor signedness fixes related to last commit.
  1723. * src/cff/cf2ft.c, src/cff/cf2intrp.c, src/cff/cffgload.c: Apply.
  1724. 2015-02-20 Werner Lemberg <wl@gnu.org>
  1725. [cff] Thinkos in bias handling.
  1726. Only the final result is always positive.
  1727. Bug introduced three commits earlier.
  1728. * src/cff/cffgload.c, src/cff/cffgload.h: Apply.
  1729. 2015-02-20 Werner Lemberg <wl@gnu.org>
  1730. [cid] Fix signedness issues and emit some better error codes.
  1731. * src/cid/cidgload.c, src/cid/cidload.h, src/cid/cidobjs.c,
  1732. src/cid/cidparse.h: Apply.
  1733. * src/cid/cidload.c: Apply.
  1734. (parse_fd_array): Reject negative values for number of dictionaries.
  1735. * src/cid/cidparse.c: Apply.
  1736. (cid_parser_new): Reject negative values for hex data length.
  1737. 2015-02-20 Werner Lemberg <wl@gnu.org>
  1738. [cff] Signedness fixes for new engine.
  1739. * src/cff/cf2arrst.c, src/cff/cf2fixed.h, src/cff/cf2ft.c,
  1740. src/cff/cf2ft.h, src/cff/cf2hints.c, src/cff/cf2intrp.c: Apply.
  1741. 2015-02-20 Werner Lemberg <wl@gnu.org>
  1742. [cff] Signedness fixes for basic infrastructure and old engine.
  1743. * include/internal/pshints.h, src/cff/cffdrivr.c,
  1744. src/cff/cffgload.c, src/cff/cffgload.h, src/cff/cffload.c,
  1745. src/cff/cffobjs.c, src/cff/cffparse.c, src/pshinter/pshrec.c: Apply.
  1746. 2015-02-19 Werner Lemberg <wl@gnu.org>
  1747. * src/truetype/ttgxvar.c (TT_Get_MM_Var): Ignore `countSizePairs'.
  1748. This is hard-coded to value 2 in `fvar' version 1.0 (and no newer
  1749. version exists), but some fonts set it incorrectly.
  1750. Problem reported by Adam Twardoch <adam@fontlab.com>.
  1751. 2015-02-19 Werner Lemberg <wl@gnu.org>
  1752. [cff] Emit better error code for invalid private dict size.
  1753. * src/cff/cffparse.c (cff_parse_private_dict): Reject negative
  1754. values for size and offset.
  1755. 2015-02-19 Werner Lemberg <wl@gnu.org>
  1756. [autofit] Fix signedness issues.
  1757. * src/autofit/afangles.c, src/autofit/afcjk.c,
  1758. src/autofit/afglobal.c, src/autofit/afhints.c,
  1759. src/autofit/aflatin.c, src/autofit/aflatin2.c, src/autofit/afwarp.c,
  1760. src/autofit/hbshim.c: Apply.
  1761. 2015-02-19 Werner Lemberg <wl@gnu.org>
  1762. [autofit] Use macros for (unsigned) flags, not enumerations.
  1763. This harmonizes with other code in FreeType (and reduces the number
  1764. of necessary casts to avoid compiler warnings).
  1765. * src/autofit/afblue.hin: Make flag macros unsigned.
  1766. * src/autofit/afblue.h: Regenerated.
  1767. * src/autofit/afcjk.h: Replace flag enumeration with macros.
  1768. * src/autofit/afcjk.c: Updated.
  1769. * src/autofit/afhints.h (AF_Flags, AF_Edge_Flags): Replace with
  1770. macros.
  1771. * src/autofit/afhints.c: Updated.
  1772. * src/autofit/aflatin.h: Replace flag enumerations with macros.
  1773. * src/autofit/aflatin.c, src/autofit/aflatin2.c: Updated.
  1774. * src/autofit/aftypes.h (AF_ScalerFlags): Replace with macros.
  1775. 2015-02-18 Werner Lemberg <wl@gnu.org>
  1776. [type1] Fix signedness issues.
  1777. * include/internal/psaux.h, include/internal/t1types.h,
  1778. src/psaux/psobjs.c, src/psaux/psobjs.h, src/psaux/t1decode.c,
  1779. src/type1/t1gload.c, src/type1/t1load.c, src/type1/t1parse.c: Apply.
  1780. 2015-02-18 Werner Lemberg <wl@gnu.org>
  1781. [psaux, type1] Fix minor AFM issues.
  1782. * include/internal/t1types.h (AFM_KernPairRec): Make indices
  1783. unsigned.
  1784. Update users.
  1785. (AFM_FontInfoRec): Make element counters unsigned.
  1786. Update users.
  1787. * src/psaux/afmparse.h (AFM_ValueRec): Add union member for unsigned
  1788. int.
  1789. * src/psaux/afmparse.c (afm_parse_track_kern, afm_parse_kern_pairs):
  1790. Reject negative values for number of kerning elements.
  1791. * src/type1/t1afm.c, src/tools/test_afm.c: Updated.
  1792. 2015-02-18 Werner Lemberg <wl@gnu.org>
  1793. Don't use `FT_PtrDist' for lengths.
  1794. Use FT_UInt instead.
  1795. * include/internal/psaux.h (PS_Table_FuncsRec, PS_TableRec,
  1796. T1_DecoderRec): Do it.
  1797. * include/internal/t1types.h (T1_FontRec): Ditto.
  1798. * src/cid/cidload.c (cid_parse_dict): Updated.
  1799. * src/pfr/pfrload.c (pfr_extra_item_load_font_id): Ditto.
  1800. * src/psaux/psobjs.c (ps_table_add), src/psaux/psobjs.h: Ditto.
  1801. * src/type1/t1load.c (parse_blend_axis_types, parse_encoding,
  1802. parse_chharstrings, parse_dict): Ditto.
  1803. * src/type42/t42parse.c (t42_parse_encoding, t42_parse_charstrings,
  1804. t42_parse_dict): Ditto.
  1805. 2015-02-18 Werner Lemberg <wl@gnu.org>
  1806. * src/type1/t1driver.c (t1_ps_get_font_value): Clean up.
  1807. This handles negative values better, avoiding many casts.
  1808. 2015-02-17 Werner Lemberg <wl@gnu.org>
  1809. [base] Fix Savannah bug #44284.
  1810. * src/base/ftcalc.c (FT_MulFix): Typos.
  1811. 2015-02-17 Werner Lemberg <wl@gnu.org>
  1812. [truetype] Finish compiler warning fixes for signedness issues.
  1813. * src/truetype/ttgxvar.c, src/truetype/ttsubpix.c,
  1814. src/truetype/ttsubpix.h: Apply.
  1815. 2015-02-17 Werner Lemberg <wl@gnu.org>
  1816. * src/truetype/ttsubpix.c: Adding missing `static' keywords.
  1817. 2015-02-17 Werner Lemberg <wl@gnu.org>
  1818. [truetype] More signedness fixes.
  1819. * include/internal/tttypes.h, src/truetype/ttinterp.h,
  1820. src/truetype/ttobjs.h, src/truetype/ttinterp.c,
  1821. src/truetype/ttobjs.c: Apply.
  1822. 2015-02-17 Werner Lemberg <wl@gnu.org>
  1823. [truetype] Various signedness fixes.
  1824. * include/internal/ftgloadr.h, src/truetype/ttpload.c: Apply.
  1825. * src/truetype/ttgload.c: Apply.
  1826. (TT_Get_VMetrics): Protect against invalid ascenders and descenders
  1827. while constructing advance height.
  1828. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1829. [base] Finish compiler warning fixes for signedness issues.
  1830. * src/base/ftglyph.c, src/base/ftlcdfil.c, src/base/ftstroke.c:
  1831. Apply.
  1832. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1833. * include/tttables.h (TT_OS2): `fsType' must be FT_UShort.
  1834. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1835. More minor signedness warning fixes.
  1836. * src/base/ftbbox.c, src/base/ftbitmap.c, src/base/fttrigon.c,
  1837. src/base/ftutil.c: Apply.
  1838. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1839. Next round of minor compiler warning fixes.
  1840. * include/internal/ftrfork.h (FT_RFork_Ref): Change `offset' member
  1841. type to `FT_Long'.
  1842. (CONST_FT_RFORK_RULE_ARRAY_BEGIN): Add `static' keyword.
  1843. * include/internal/ftstream.h (FT_Stream_Pos): Return `FT_ULong'.
  1844. * src/base/ftoutln.c, src/base/ftrfork.c, src/base/ftstream.c:
  1845. Signedess fixes.
  1846. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1847. Various minor signedness fixes.
  1848. * include/ftadvanc.h, include/internal/ftobjs.h,
  1849. src/base/ftgloadr.c, src/base/ftobjs.c: Apply.
  1850. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1851. New `TYPEOF' macro.
  1852. This helps suppress signedness warnings, avoiding issues with
  1853. implicit conversion changes.
  1854. * include/config/ftconfig.h, builds/unix/ftconfig.in,
  1855. builds/vms/ftconfig.h (TYPEOF): Define.
  1856. * include/internal/ftobjs.h (FT_PAD_FLOOR, FT_PIX_FLOOR),
  1857. src/autofit/afwarp.h (AF_WARPER_FLOOR): Use it.
  1858. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1859. * src/base/ftsystem.c: Use casts in standard C function wrappers.
  1860. (ft_alloc, ft_realloc, ft_ansi_stream_io, FT_Stream_Open): Do it.
  1861. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1862. Fix Savannah bug #44261.
  1863. * builds/unix/detect.mk (setup) [unix]: Set `CONFIG_SHELL' in the
  1864. environment also while calling the configure script.
  1865. 2015-02-16 Werner Lemberg <wl@gnu.org>
  1866. * include/internal/ftmemory.h: Add some `FT_Offset' casts.
  1867. (FT_MEM_SET, FT_MEM_COPY, FT_MEM_MOVE, FT_ARRAY_ZERO, FT_ARRAY_COPY,
  1868. FT_MEM_MOVE): Do it.
  1869. 2015-02-15 Werner Lemberg <wl@gnu.org>
  1870. [base] Clean up signedness issues in `ftdbgmem.c'.
  1871. Also fix other minor issues.
  1872. * src/base/ftdbgmem.c (FT_MemTableRec): Replace all FT_ULong types
  1873. with FT_Long for consistency.
  1874. (ft_mem_primes): Change type to `FT_Int'.
  1875. (ft_mem_closest_prime, ft_mem_table_set): Updated.
  1876. (ft_mem_debug_panic, ft_mem_debug_alloc, ft_mem_debug_free,
  1877. ft_mem_debug_realloc): Use `static' keyword and fix signedness
  1878. warnings where necessary.
  1879. (ft_mem_table_resize, ft_mem_table_new, ft_mem_table_destroy,
  1880. ft_mem_table_get_nodep, ft_mem_debug_init, FT_DumpMemory): Fix types
  1881. and add or remove casts to avoid signedness warnings.
  1882. 2015-02-15 Werner Lemberg <wl@gnu.org>
  1883. [base] Clean up signedness in arithmetic functions.
  1884. This makes the code more readable and reduces compiler warnings.
  1885. * src/base/ftcalc.c (FT_MulDiv, FT_MulDiv_No_Round, FT_MulFix,
  1886. FT_DivFix): Convert input parameters to unsigned, do the
  1887. computation, then convert the result back to signed.
  1888. (ft_corner_orientation): Fix casts.
  1889. 2015-02-07 Werner Lemberg <wl@gnu.org>
  1890. [sfnt] Fix Savannah bug #44184.
  1891. * src/sfnt/ttload.c (check_table_dir, tt_face_load_font_dir): No
  1892. longer reject `htmx' and `vmtx' tables with invalid length but
  1893. sanitize them.
  1894. 2015-02-06 Jon Anderson <jon@websupergoo.com>
  1895. [truetype] Fix regression in the incremental glyph loader.
  1896. * src/truetype/ttgload.c (load_truetype_glyph): For incremental
  1897. fonts, the glyph index may be greater than the number of glyphs
  1898. indicated, so guard the check with a preprocessor conditional.
  1899. 2015-02-06 Werner Lemberg <wl@gnu.org>
  1900. [autofit] Fix potential memory leak.
  1901. While this doesn't show up with FreeType, exactly the same code
  1902. leaks with ttfautohint's modified auto-hinter code (which gets used
  1903. in a slightly different way).
  1904. It certainly doesn't harm since it is similar to already existing
  1905. checks in the code for embedded arrays.
  1906. * src/autofit/afhints.c (af_glyph_hints_reload): Set `max_contours'
  1907. and `max_points' for all cases.
  1908. 2015-01-31 Werner Lemberg <wl@gnu.org>
  1909. [autofit] Add support for Thai script.
  1910. Thanks to Ben Mitchell <ben@rosettatype.com> for guidance with blue
  1911. zone characters!
  1912. * src/autofit/afblue.dat: Add blue zone data for Thai.
  1913. * src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
  1914. * src/autofit/afscript.h: Add Thai standard characters.
  1915. * src/autofit/afranges.c: Add Thai data.
  1916. * src/autofit/afstyles.h: Add Thai data.
  1917. 2015-01-23 Behdad Esfahbod <behdad@behdad.org>
  1918. [raster] Handle `FT_RASTER_FLAG_AA' correctly.
  1919. This fixes a breakage caused by the commit `[raster] Remove
  1920. 5-level gray AA mode from monochrome rasterizer.'.
  1921. Problem reported by Markus Trippelsdorf <markus@trippelsdorf.de>.
  1922. * src/raster/ftraster.c (ft_black_render): Handle
  1923. `FT_RASTER_FLAG_AA'.
  1924. * src/raster/ftrend1.c (ft_raster1_render): Remove gray AA mode
  1925. remnants.
  1926. 2015-01-18 Werner Lemberg <wl@gnu.org>
  1927. * src/base/ftobjs.c (FT_New_Library): Fix compiler warning.
  1928. 2015-01-18 Chris Liddell <chris.liddell@artifex.com>
  1929. [raster] Fix Savannah bug #44022.
  1930. Add fallback for glyphs with degenerate bounding boxes.
  1931. If a glyph has only one very narrow feature, the bbox can end up
  1932. with either the width or height of the bbox being 0, in which case
  1933. no raster memory is allocated and no attempt is made to render the
  1934. glyph. This is less than ideal when the drop-out compensation in
  1935. the rendering code would actually result in the glyph being
  1936. rendered.
  1937. This problem can be observed with the `I' glyph (gid 47) in the
  1938. Autodesk RomanS TrueType font.
  1939. * src/raster/ftrend1.c (ft_raster1_render): Add a fallback if either
  1940. dimension is zero to explicitly round up/down (instead of simply
  1941. round).
  1942. 2015-01-17 Werner Lemberg <wl@gnu.org>
  1943. Add some tools to handle yearly copyright notice updates.
  1944. We are now following the GNU guidelines: A new release automatically
  1945. means that the copyright year of all affected files gets updated; it
  1946. is no longer used to track years of modification changes.
  1947. * src/tools/update-copyright-year: New Perl script.
  1948. * src/tools/update-copyright: New shell script that calls
  1949. `update-copyright-year' on all files.
  1950. * src/tools/no-copyright: Exceptions that should not be handled by
  1951. `update-copyright'
  1952. 2015-01-14 Werner Lemberg <wl@gnu.org>
  1953. * docs/CHANGES: Updated, using a description from Behdad.
  1954. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  1955. * src/autofit/afmodule.c (af_autofitter_done): Fix compiler warning.
  1956. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  1957. [autofit] Add embedded array of segments and edges.
  1958. Avoids multiple mallocs per typical glyphs.
  1959. With this and recent changes to avoid mallocs, the thread-safe
  1960. stack-based loader is now as fast as the previous model that had one
  1961. cached singleton.
  1962. * src/autofit/afhints.h (AF_SEGMENTS_EMBEDDED, AF_EDGES_EMBEDDED):
  1963. New macros.
  1964. (AF_AxisHintsRec): Add two arrays for segments and edges.
  1965. * src/autofit/afhints.c (af_axis_hints_new_segment): Only allocate
  1966. data if number of segments exceeds given threshold value.
  1967. (af_axis_hints_new_edge): Only allocate data if number of edges
  1968. exceeds given threshold value.
  1969. (af_glyph_hints_done): Updated.
  1970. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  1971. [autofit] Add embedded arrays for points and contours.
  1972. This avoids at least two malloc calls for typical glyphs.
  1973. * src/autofit/afhints.h (AF_POINTS_EMBEDDED, AF_CONTOURS_EMBEDDED):
  1974. New macros.
  1975. (AF_GlyphHintsRec): Add two arrays for contours and points.
  1976. * src/autofit/afhints.c (af_glyph_hints_init, af_glyph_hints_done):
  1977. Updated.
  1978. (af_glyph_hints_reload): Only allocate data if number of contours or
  1979. points exceeds given threshold values.
  1980. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  1981. [autofit] Allocate hints object on the stack.
  1982. This avoids one malloc per load.
  1983. * src/autofit/afloader.h (AF_LoaderRec): Change type of `hints' to
  1984. `AF_GlyphHints'.
  1985. Update prototype.
  1986. * src/autofit/afloader.c (af_loader_init): Use `AF_GlyphHints'
  1987. parameter instead of `FT_Memory'.
  1988. (af_loader_done): Directly reset `load_hints'.
  1989. (af_loader_load_g): Updated.
  1990. * src/autofit/afmodule.c (af_autofitter_load_glyph): Use local
  1991. `hints' object.
  1992. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  1993. [autofit] Reuse slot glyph loader.
  1994. No need to create a new glyph loader; we can reuse the one from
  1995. `slot->internal->loader'. It's hard to tell why it was written that
  1996. way originally, but new code looks sound and correct to me, and
  1997. avoids lots of allocations.
  1998. * src/autofit/afloader.c (af_loader_init): Change return type to
  1999. `void'.
  2000. Don't call `FT_GlyphLoader_New'.
  2001. (af_loader_reset): Don't call `FT_GlyphLoader_Rewind'.
  2002. (af_loader_load_g): Update code to use `internal->loader', which
  2003. doesn't need copying of data.
  2004. * src/autofit/afloader.h (AF_LoaderRec): Remove `gloader' member.
  2005. Update prototype.
  2006. * src/autofit/afmodule.c (af_autofitter_load_glyph): Updated.
  2007. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2008. [autofit] Remove (unused) support for composite glyphs.
  2009. We never have to deal with composite glyphs in the autohinter, as
  2010. those will be loaded into FORMAT_OUTLINE by the recursed
  2011. `FT_Load_Glyph' function.
  2012. In the rare cases that FT_LOAD_NO_RECURSE is set, it will imply
  2013. FT_LOAD_NO_SCALE as per `FT_Load_Glyph', which then implies
  2014. FT_LOAD_NO_HINTING:
  2015. /* resolve load flags dependencies */
  2016. if ( load_flags & FT_LOAD_NO_RECURSE )
  2017. load_flags |= FT_LOAD_NO_SCALE |
  2018. FT_LOAD_IGNORE_TRANSFORM;
  2019. if ( load_flags & FT_LOAD_NO_SCALE )
  2020. {
  2021. load_flags |= FT_LOAD_NO_HINTING |
  2022. FT_LOAD_NO_BITMAP;
  2023. load_flags &= ~FT_LOAD_RENDER;
  2024. }
  2025. and as such the auto-hinter is never called. Thus, the recursion in
  2026. `af_loader_load_g' never actually happens. So remove the depth
  2027. counter as well.
  2028. * src/autofit/afloader.c (af_loader_load_g): Remove `depth'
  2029. parameter.
  2030. <FT_GLYPH_FORMAT_COMPOSITE>: Remove associated code.
  2031. (af_loader_load_glyph): Updated.
  2032. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2033. [raster] Fix uninitialized memory access.
  2034. Apparently `ras.cProfile' might be uninitialized. This will be the
  2035. case if `ras.top == ras.cProfile->offset', as can be seen in
  2036. `End_Profile'. The overshoot code introduced in a change `Fix B/W
  2037. rasterization of subglyphs with different drop-out modes.' (from
  2038. 2009-06-18) violated this, accessing `ras.cProfile->flags'
  2039. unconditionally just before calling `End_Profile' (which then
  2040. detected that `cProfile' is uninitialized and didn't touch it).
  2041. This was harmless, and was not detected by valgrind before because
  2042. the objects were allocated on the `raster_pool', which was always
  2043. initialized. With recent change to allocate raster buffers on the
  2044. stack, valgrind now reported this invalid access.
  2045. * src/raster/ftraster.c (Convert_Glyph): Don't access an
  2046. uninitialized `cProfile'.
  2047. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2048. [smooth] Fix uninitialized memory access.
  2049. Looks like `ras.span_y' could always be used without initialization.
  2050. This was never detected by valgrind before because the library-wide
  2051. `raster_pool' was used for the worker object and `raster_pool' was
  2052. originally zero'ed. But subsequent reuses of it were using `span_y'
  2053. uninitialized. With the recent change to not use `render_pool' and
  2054. allocate worker and buffer on the stack, valgrind now detects this
  2055. uninitialized access.
  2056. * src/smooth/ftgrays.c (gray_raster_render): Initialize
  2057. `ras.span_y'.
  2058. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2059. [base] Don't initialize unused `driver->glyph_loader'.
  2060. * src/base/ftobjs.c (Destroy_Driver): Don't call
  2061. `FT_GlyphLoader_Done'.
  2062. (FT_Add_Module): Don't call `FT_GlyphLoader_New'.
  2063. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2064. [base] Don't allocate `library->raster_pool' anymore.
  2065. It's unused after the following commits:
  2066. [raster] Allocate render pool for mono rasterizer on the stack.
  2067. [raster] Remove 5-level gray AA mode from monochrome rasterizer.
  2068. The value of FT_RENDER_POOL_SIZE still serves the purpose it used to
  2069. serve, which is, to adjust the pool size. But the pool is now
  2070. allocated on the stack on demand.
  2071. * src/base/ftobjs.c (FT_New_Library, FT_Done_Library): Implement.
  2072. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2073. [base] Do not reorder library->renderers upon use.
  2074. Instead of keeping `library->renderers' in a MRU order, just leave
  2075. it as-is. The MRU machinery wasn't thread-safe.
  2076. With this patch, rasterizing glyphs from different faces from
  2077. different threads doesn't fail choosing rasterizer
  2078. (FT_Err_Cannot_Render_Glyph).
  2079. Easiest to see that crash was to add a `printf' (or otherwise let
  2080. thread yield in FT_Throw with debugging enabled).
  2081. * src/base/ftobjs.c (FT_Render_Glyph_Internal), src/base/ftoutln.c
  2082. (FT_Outline_Render): Don't call `FT_Set_Renderer'.
  2083. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2084. [raster] Allocate render pool for mono rasterizer on the stack.
  2085. Instead of using the `render_pool' member of `FT_Library' that is
  2086. provided down to the rasterizer, completely ignore that and allocate
  2087. needed objects on the stack instead.
  2088. With this patch, rasterizing glyphs from different faces from
  2089. different threads doesn't crash in the monochrome rasterizer.
  2090. * src/raster/ftraster.c (black_TRaster): Remove `buffer',
  2091. `buffer_size', and `worker' members.
  2092. (ft_black_render): Create `buffer' locally.
  2093. (ft_black_reset): Updated.
  2094. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2095. [raster] Remove 5-level gray AA mode from monochrome rasterizer.
  2096. It was off by default and couldn't be turned on at runtime. And the
  2097. smooth rasterizer superceded it over ten years ago. No point in
  2098. keeping. Comments suggested that it was there for compatibility
  2099. with FreeType 1.
  2100. 550 lines down.
  2101. * src/raster/ftraster.c (FT_RASTER_OPTION_ANTI_ALIASING,
  2102. RASTER_GRAY_LINES): Remove macros and all associated code.
  2103. (black_TWorker): Remove `gray_min_x' and `gray_max_x'.
  2104. (black_TRaster): Remove `grays' and `gray_width'.
  2105. (Vertical_Sweep_Init, Vertical_Sweep_Span, Vertical_Sweep_Drop,
  2106. ft_black_render): Updated.
  2107. * src/raster/ftrend1.c (ft_raster1_render): Simplify code.
  2108. (ft_raster5_renderer_class): Removed.
  2109. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2110. [smooth] Allocate render pool for smooth rasterizer on the stack.
  2111. Instead of using the `render_pool' member of `FT_Library' that is
  2112. provided down to the rasterizer, completely ignore that and allocate
  2113. needed objects on the stack instead.
  2114. With this patch, rasterizing glyphs from different faces from
  2115. different threads doesn't crash in the smooth rasterizer.
  2116. Bugs:
  2117. https://bugzilla.redhat.com/show_bug.cgi?id=678397
  2118. https://bugzilla.redhat.com/show_bug.cgi?id=1004315
  2119. https://bugzilla.redhat.com/show_bug.cgi?id=1165471
  2120. https://bugs.freedesktop.org/show_bug.cgi?id=69034
  2121. * src/smooth/ftgrays.c (gray_TRaster): Remove `buffer',
  2122. `buffer_size', `band_size', and `worker' members.
  2123. (gray_raster_render): Create `buffer', `buffer_size', and
  2124. `band_size' locally.
  2125. (gray_raster_reset): Updated.
  2126. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2127. [truetype] Allocate TT_ExecContext in TT_Size instead of TT_Driver.
  2128. Previously the code had stipulation for using a per-TT_Size exec
  2129. context if `size->debug' was true. But there was no way that
  2130. `size->debug' could *ever* be true. As such, the code was always
  2131. using the singleton `TT_ExecContext' that was stored in `TT_Driver'.
  2132. This was, clearly, not threadsafe.
  2133. With this patch, loading glyphs from different faces from different
  2134. threads doesn't crash in the bytecode loader code.
  2135. * src/truetype/ttobjs.h (TT_SizeRec): Remove `debug' member.
  2136. (TT_DriverRec): Remove `context' member.
  2137. * src/truetype/ttobjs.c (tt_size_run_fpgm, tt_size_run_prep): Remove
  2138. `TT_ExecContext' code related to a global `TT_Driver' object.
  2139. (tt_driver_done): Don't remove `TT_ExecContext' object here but ...
  2140. (tt_size_done_bytecode): ... here.
  2141. (tt_driver_init): Don't create `TT_ExecContext' object here but ...
  2142. (tt_size_init_bytecode): ... here, only on demand.
  2143. * src/truetype/ttinterp.c (TT_Run_Context): Remove defunct debug
  2144. code.
  2145. (TT_New_Context): Remove `TT_ExecContext' code related to a global
  2146. `TT_Driver' object.
  2147. * src/truetype/ttinterp.h: Updated.
  2148. * src/truetype/ttgload.c (TT_Hint_Glyph, tt_loader_init): Updated.
  2149. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2150. [autofit] Allocate AF_Loader on the stack instead of AF_Module.
  2151. Stop sharing a global `AF_Loader'. Allocate one on the stack during
  2152. glyph load.
  2153. Right now this results in about 25% slowdown, to be fixed in a
  2154. following commit.
  2155. With this patch loading glyphs from different faces from different
  2156. threads doesn't immediately crash in the autohinting loader code.
  2157. Bugs:
  2158. https://bugzilla.redhat.com/show_bug.cgi?id=1164941
  2159. * src/autofit/afloader.c (af_loader_init): Pass
  2160. `AF_Loader' and `FT_Memory' instead of `AF_Module' as arguments.
  2161. (af_loader_reset, af_loader_load_glyph): Also pass `loader' as
  2162. argument.
  2163. (af_loader_done): Use `AF_Loader' instead of `AF_Module' as
  2164. argument.
  2165. * src/autofit/afmodule.c (af_autofitter_init): Don't call
  2166. `af_loader_init'.
  2167. (af_autofitter_done): Don't call `af_loader_done'.
  2168. (af_autofitter_load_glyph): Use a local `AF_Loader' object.
  2169. * src/autofit/afloader.h: Include `afmodule.h'.
  2170. Update prototypes.
  2171. Move typedef for `AF_Module' to...
  2172. * src/autofit/afmodule.h: ... this place.
  2173. No longer include `afloader.h'.
  2174. 2015-01-14 Behdad Esfahbod <behdad@behdad.org>
  2175. * src/type42/t42objs.h (T42_DriverRec): Remove unused member.
  2176. 2015-01-12 Werner Lemberg <wl@gnu.org>
  2177. Fix Savannah bug #43976.
  2178. Assure that FreeType's internal include directories are found before
  2179. `CPPFLAGS' (which might be set by the user in the environment), and
  2180. `CPPFLAGS' before `CFLAGS'.
  2181. * builds/freetype.mk (FT_CFLAGS): Don't add `INCLUDE_FLAGS'.
  2182. (FT_COMPILE): Make this a special variable for compiling only the
  2183. files handled in `freetype.mk'.
  2184. (.c.$O): Removed, unused.
  2185. * src/*/rules.mk (*_COMPILE): Fix order of include directories.
  2186. 2015-01-11 Werner Lemberg <wl@gnu.org>
  2187. [truetype] Prettyfing.
  2188. * src/truetype/ttinterp.c (project, dualproj, fast_project,
  2189. fast_dualproj): Rename to...
  2190. (PROJECT, DUALPROJ, FAST_PROJECT, FAST_DUALPROJ): ... this.
  2191. 2015-01-11 Werner Lemberg <wl@gnu.org>
  2192. * src/truetype/ttinterp.c (Ins_JROT, Ins_JROF): Simplify.
  2193. Based on a patch from Behdad.
  2194. 2015-01-11 Werner Lemberg <wl@gnu.org>
  2195. * src/truetype/ttinterp.c (Ins_SxVTL): Simplify function call.
  2196. 2015-01-11 Werner Lemberg <wl@gnu.org>
  2197. * src/truetype/ttinterp.c (Normalize): Remove unused argument.
  2198. 2015-01-11 Werner Lemberg <wl@gnu.org>
  2199. [truetype] More macro expansions.
  2200. * src/truetype/ttinterp.c (FT_UNUSED_EXEC): Remove macro by
  2201. expansion.
  2202. 2015-01-11 Werner Lemberg <wl@gnu.org>
  2203. [truetype] More macro expansions.
  2204. * src/truetype/ttinterp.c (INS_ARG): Remove macro by expansion,
  2205. adjusting funtion calls where necessary.
  2206. (FT_UNUSED_ARG): Removed, no longer needed.
  2207. 2015-01-10 Werner Lemberg <wl@gnu.org>
  2208. [truetype] More macro expansions.
  2209. Based on a patch from Behdad.
  2210. * src/truetype/ttinterp.c (DO_*): Expand macros into corresponding
  2211. `Ins_*' functions.
  2212. (TT_RunIns): Replace `DO_*' macros with `Ins_*' function calls.
  2213. (ARRAY_BOUND_ERROR): Remove second definition, which is no longer
  2214. needed.
  2215. (Ins_SVTCA, Ins_SPVTCA, Ins_SFVTCA): Replaced with...
  2216. (Ins_SxyTCA): New function.
  2217. 2015-01-10 Werner Lemberg <wl@gnu.org>
  2218. [truetype] Remove TT_CONFIG_OPTION_INTERPRETER_SWITCH.
  2219. Behdad suggested this code simplification, and nobody objected...
  2220. * include/config/ftoption.h, devel/ftoption.h
  2221. (TT_CONFIG_OPTION_INTERPRETER_SWITCH): Remove.
  2222. * src/truetype/ttinterp.c [TT_CONFIG_OPTION_INTERPRETER_SWITCH]:
  2223. Remove related code.
  2224. (ARRAY_BOUND_ERROR): Use do-while loop.
  2225. 2015-01-10 Werner Lemberg <wl@gnu.org>
  2226. [truetype] More macro expansions.
  2227. * src/truetype/ttinterp.c, src/truetype/ttinterp.h (EXEC_ARG_,
  2228. EXEC_ARG): Remove by replacing with expansion.
  2229. 2015-01-10 Werner Lemberg <wl@gnu.org>
  2230. [truetype] More macro expansions.
  2231. Based on a patch from Behdad.
  2232. * src/truetype/ttinterp.c (SKIP_Code, GET_ShortIns, NORMalize,
  2233. SET_SuperRound, ROUND_None, INS_Goto_CodeRange, CUR_Func_move,
  2234. CUR_Func_move_orig, CUR_Func_round, CUR_Func_cur_ppem,
  2235. CUR_Func_read_cvt, CUR_Func_write_cvt, CUR_Func_move_cvt,
  2236. CURRENT_Ratio, INS_SxVTL, COMPUTE_Funcs, COMPUTE_Round,
  2237. COMPUTE_Point_Displacement, MOVE_Zp2_Point): Remove by replacing
  2238. with expansion.
  2239. (Cur_Func_project, CUR_Func_dualproj, CUR_fast_project,
  2240. CUR_fast_dualproj): Replace with macros `project', `dualproj',
  2241. `fast_project', `fast_dualproj'.
  2242. 2015-01-10 Werner Lemberg <wl@gnu.org>
  2243. [truetype] More macro expansions.
  2244. * src/truetype/ttinterp.c (EXEC_OP_, EXEC_OP): Remove by replacing
  2245. with expansion.
  2246. 2015-01-10 Werner Lemberg <wl@gnu.org>
  2247. [truetype] Remove code for static TrueType interpreter.
  2248. This is a follow-up patch.
  2249. * src/truetype/ttinterp.c, src/truetype/ttinterp.h
  2250. [TT_CONFIG_OPTION_STATIC_INTERPRETER,
  2251. TT_CONFIG_OPTION_STATIC_RASTER]: Remove macros and related code.
  2252. 2015-01-10 Werner Lemberg <wl@gnu.org>
  2253. * src/truetype/ttinterp.c (CUR): Remove by replacing with expansion.
  2254. This starts a series of patches that simplifies the code of the
  2255. bytecode interpreter.
  2256. ----------------------------------------------------------------------------
  2257. Copyright 2015 by
  2258. David Turner, Robert Wilhelm, and Werner Lemberg.
  2259. This file is part of the FreeType project, and may only be used, modified,
  2260. and distributed under the terms of the FreeType project license,
  2261. LICENSE.TXT. By continuing to use, modify, or distribute this file you
  2262. indicate that you have read the license and understand and accept it
  2263. fully.
  2264. Local Variables:
  2265. version-control: never
  2266. coding: utf-8
  2267. End: