LibreOffice Writer Formula hat

I am trying to create a fornula that use a hat over a letter. If I use hat u I get a hat but there is a considerable gap between the letter and the hat:
Screenshot 2025-12-21 at 16.40.02

Has anyone seen the same issue and are there any fixes?

Document is saved as an odt file. I have changed the fonts used in formulas to Latin Modern Math.

Version: 25.8.4.2 (X86_64)
Build ID: 290daaa01b999472f0c7a3890eb6a550fd74c6df
CPU threads: 4; OS: macOS 10.15.7; UI render: Skia/Metal; VCL: osx
Locale: en-GB (en_GB.UTF-8); UI: en-US
Calc: threaded

https://wiki.documentfoundation.org/Ask/Guide_-_How_to_use_the_Ask_site#More_details #More_details

Excessive spacing on letters in hat in formula

It definitely is not a writer issue but a math one because you obviously inserted a formula object.

And you likely already fiddled in Math settings because out of the box the circumflex hat is closer to the symbol than in your screenshot.

  1. Edit the formula (double-click on it to launch Math)
  2. Menu Format>Spacing
  3. Press button Category to expand drop-down submenu
  4. Select Symbols
  5. The dialog now shows two settings: Primary height and Minimum spacing
  6. Modify Primary Height (0% will glue hat on top of letter)
  7. OK

Iterate until you find your expectation.

PS! when asking here, always mention OS name, exact LO version like 25.8.4.2 (not “latest” which does not mean anything due to different pace on different platforms) and save format. The latter is very important because most solutions are only valid for .odt.

Thanks for your reply. The only fiddle I have done is to change the font used for math formulas to Latin Modern Math. I have checked Symbols spacing and Primary Height is set to 0%.

Magic: I closed the document, reopened it and then recreated the formula. Now the hat is placed perfectly.