ladybird/Userland/Libraries
Nico Weber f34da6396f LibPDF: Update font size after getting font from cache
Page 1 of 0000277.pdf does:

    BT 22 0 0 22  59  28 Tm /TT2 1 Tf
        (Presented at Photonics West OPTO, February 17, 2016) Tj ET
    BT 32 0 0 32 269 426 Tm /TT1 1 Tf
        (Robert W. Boyd) Tj ET
    BT 22 0 0 22 253 357 Tm /TT2 1 Tf
        (Department of Physics and) Tj ET
    BT 22 0 0 22 105 326 Tm /TT2 1 Tf
        (Max-Planck Centre for Extreme and Quantum Photonics) Tj ET

Every line begins a text operation, then updates the font matrix,
selects a font (TT2, TT1, TT2, TT1), draws some text and ends the text
operation.

`Tm` (which sets the font matrix) contains a scale, and uses that
to update the font size of the currently-active font (cf #20084).
But in this file, we `Tm` first and `Tf` (font selection) second,
so this updates the size of the old font. So when we pull it out
of the cache again on line 3, it would still have the old size
from the `Tm` on line 2.

(The whole text scaling logic in LibPDF imho needs a rethink; the
current approach also causes issues with zero-width glyphs which
currently lead to divisions by zero. But that's for another PR.)

Fixes another regression from c8510b58a3 (which I've accidentally
referred to by 2340e834cd in another commit).
2023-11-26 19:05:13 -05:00
..
LibAccelGfx LibAccelGfx+LibWeb: Discard painting of commands outside of viewport 2023-11-26 21:26:26 +01:00
LibArchive AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibAudio LibAudio: Speed up WavWriter by buffering output data 2023-11-23 18:05:22 -05:00
LibC Userland+Tests: Add initial riscv64 support 2023-11-10 10:30:08 -07:00
LibCards LibCards/CardPainter: Add a helper for accessing the caches 2023-11-24 11:45:32 +00:00
LibChess AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibCMake
LibCodeComprehension AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibCompress LibCompress/LZW: Use its own debug flag 2023-11-12 13:56:27 +01:00
LibConfig
LibCore AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibCoredump Userland+Tests: Add initial riscv64 support 2023-11-10 10:30:08 -07:00
LibCpp AK+Everywhere: Remove the null state of DeprecatedString 2023-10-13 18:33:21 +03:30
LibCrypt
LibCrypto LibCrypto: Add SECP384r1 implementation 2023-11-11 14:40:10 +03:30
LibDebug Userland+Tests: Add initial riscv64 support 2023-11-10 10:30:08 -07:00
LibDesktop AppFile: Add helpers for dealing with AppFile paths 2023-11-09 23:35:52 +01:00
LibDeviceTree
LibDiff
LibDNS LibDNS: Ensure DNS name and label sizes are within expected limits 2023-11-14 10:12:44 +01:00
LibDSP
LibEDID
LibELF Userland+Tests: Add initial riscv64 support 2023-11-10 10:30:08 -07:00
LibFileSystem
LibFileSystemAccessClient AK+Everywhere: Remove the null state of DeprecatedString 2023-10-13 18:33:21 +03:30
LibGemini AK+Everywhere: Remove the null state of DeprecatedString 2023-10-13 18:33:21 +03:30
LibGfx LibGfx+LibWeb: Add ImmutableBitmap for images bitmap caching in painter 2023-11-26 12:55:43 +01:00
LibGL LibGL: Optimize appends in gl_vertex 2023-10-15 12:14:07 +02:00
LibGLSL
LibGPU LibGL+Lib*GPU: Set model view and projection matrices separately 2023-10-15 12:14:07 +02:00
LibGUI Taskbar+WindowServer: Adding to Quick Launch via windows :^) 2023-11-09 23:35:52 +01:00
LibHTTP LibHTTP: Fix issues with HTTP POST request and requests with a body 2023-10-31 07:09:26 +01:00
LibIDL AK+LibIDL: Put IDL dbgln statement behind a debug flag 2023-11-15 23:42:53 +01:00
LibImageDecoderClient Ladybird: Decode images out of process 2023-10-27 07:26:32 +02:00
LibIMAP LibIMAP: Make parsing of atom data fallible 2023-11-08 09:36:37 +01:00
LibIPC
LibJIT LibJS/JIT: Add a builtin for Math.abs 2023-11-17 19:06:25 +01:00
LibJS LibJS/JIT: Add fast path for JumpConditional where accumulator is Int32 2023-11-26 19:32:51 +01:00
LibKeyboard
LibLine LibLine: Reset state after invalid character in DSR response 2023-11-18 18:33:00 +03:30
LibLocale
LibMain
LibManual AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibMarkdown LibMarkdown: Render slugified anchor tag in heading 2023-10-30 10:39:59 +00:00
LibPartition
LibPCIDB
LibPDF LibPDF: Update font size after getting font from cache 2023-11-26 19:05:13 -05:00
LibProtocol
LibRegex LibRegex: Support non-ASCII case-insensitive character comparisons 2023-11-08 12:54:26 -05:00
LibSanitizer
LibSoftGPU LibSoftGPU: Optimize GPU::Vertex lists 2023-10-15 12:14:07 +02:00
LibSQL AK+Everywhere: Remove the null state of DeprecatedString 2023-10-13 18:33:21 +03:30
LibSymbolication
LibSyntax AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibSystem
LibTest LibTest: Fix integer overflow in Gen::unsigned_int(u32) 2023-11-18 10:01:29 +01:00
LibTextCodec LibTextCodec: Add PDFDocEncoding decoder 2023-11-22 09:08:06 -07:00
LibThreading
LibTimeZone LibTimeZone: Handle systems with varying zoneinfo file locations 2023-11-17 19:07:53 +01:00
LibTLS LibTLS: Add support for SECP384r1 2023-11-11 14:40:10 +03:30
LibUnicode LibUnicode: Define case-insensitive string comparison more generically 2023-11-08 12:54:26 -05:00
LibUSBDB
LibVideo AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibVirtGPU LibGL+Lib*GPU: Set model view and projection matrices separately 2023-10-15 12:14:07 +02:00
LibVT Kernel+Userland: Replace the beep syscall with the new /dev/beep device 2023-11-03 15:19:33 +01:00
LibWasm AK: Rename GenericTraits to DefaultTraits 2023-11-09 10:05:51 -05:00
LibWeb LibAccelGfx+LibWeb: Discard painting of commands outside of viewport 2023-11-26 21:26:26 +01:00
LibWebSocket
LibWebView LibWebView: Scroll inspected elements into view with a slight offset 2023-11-24 17:19:08 -05:00
LibX86 LibX86: Support decoding F2 SSE instructions 2023-11-10 11:01:59 +01:00
LibXML
CMakeLists.txt LibAccelGfx+Meta: Introduce OpenGL painting library 2023-10-29 17:13:23 +01:00