Paul Sherliker
2025-Feb-20 15:48 UTC
[R] Code \255 no longer working to produce a short dash in base R PDF graphs
Ivan Krylov wrote:>> text(1, 11, "baseline\255defined")>> text(1, 9, "done")>> graphics.off()>>>> They like that dash - but I never knew what it was called.>>>> Recently work updated my PC to the latest version of Windows, and,>> perforce, I updated to the latest version of R (4.4.2).>>Nowadays, the session encoding on appropriately new versions of Windows is UTF-8 [*]. Previously, the native encoding of the R session corresponded to the ANSI encoding of your computer, most likely CP1252.>Let's see what does \255 mean in that encoding:>>i>conv('\255', 'CP1252', '') |> utf8ToInt() |> as.hexmode() # [1] "ad">>>Does '\uad' work for you?>>-->Best regards,>IvanInside my pasted-together constructed titles, I have to use \u{ad}, but _that_ works perfectly. Thank you very much indeed! Paul [[alternative HTML version deleted]]