Incidencia #44906

Qt: Wrong font (size) on current production widget

Abrir Fecha: 2022-06-22 20:11 Última actualización: 2022-07-07 23:46

Informador:
Propietario:
Tipo:
Estado:
Cerrado
Componente:
Prioridad:
5 - Medium
Gravedad:
5 - Medium
Resolución:
Fixed
Fichero:
2

Details

Even with #44389 patch applied, ddeanbrown reports that the font is not right:

"Applying the patch did not have any affect."

That's on MacOS, where Qt often seems to have behavior different from other platforms (not only bugs - there's even documented differences)

Ticket History (3/12 Histories)

2022-06-22 20:11 Updated by: cazfi
  • New Ticket "Qt: Wrong font (size) on current production widget" created
2022-06-26 00:31 Updated by: cazfi
Comentario

Attached patch that would produce some logging for debugging purposes - not meant to ever become part of freeciv distribution. For S3_0.

It would be great if ddeanbrown or someone else able to reproduce the problem could get the logs from a run with this patch applied. Launch the client, Start a New Game, W)ait with all the other units until Settlers activate, and then build a city with it (to get a city dialog opened), close the client.

2022-06-26 00:39 Updated by: cazfi
Comentario

Example output of what I got with 'gui_qt_font_default="Liberation Sans,15,-1,5,50,0,0,0,0,0"' in ~/.freeciv/freeciv-client-rc-3.0

---

Running ./client/freeciv-qt
Encodings: Data=UTF-8, Local=UTF-8, Internal=UTF-8
2: gui_qt_font_default : Liberation Sans,15,-1,5,50,0,0,0,0,0.
2: gui_qt_font_chatline : Liberation Mono,13,-1,5,50,0,0,0,0,0.
2: gui_qt_font_city_names : Liberation Sans,11,-1,5,75,0,0,0,0,0.
2: gui_qt_font_city_productions : Noto Sans,13,-1,5,75,0,0,0,0,0.
2: gui_qt_font_reqtree_text : Noto Sans,15,-1,5,75,0,0,0,0,0.
2: App default after change callbacks : Liberation Sans,15,-1,5,50,0,0,0,0,0.
2: Loading tileset "hexemplio".
2: Loading tileset "hexemplio".
2: Drawing font for progress bar : Liberation Sans,15,-1,5,50,0,0,0,0,0.
2: Production combo itself : Liberation Sans,15,-1,5,50,0,0,0,0,0.
2: Production combo uses : Liberation Sans,15,-1,5,50,0,0,0,0,0.
2: Progress bar painter : Liberation Sans,15,-1,5,75,0,0,0,0,0.
2: last message repeated 2 times

2022-06-26 04:38 Updated by: ddeanbrown
Comentario
(This comment has been deleted)
2022-06-26 04:42 Updated by: ddeanbrown
Comentario

Here's log from my Mac with the patch -


Could not create pixmap from /Applications/freeciv.app/Contents/share/freeciv/themes/gui-qt/Classic/pattern-game.jpg
2: gui_qt_font_default : Arial,14,-1,5,50,0,0,0,0,0,Regular.
2: gui_qt_font_chatline : .AppleSystemUIFont,10,-1,5,50,0,0,0,0,0,Regular.
2: gui_qt_font_city_names : Gill Sans,18,-1,5,50,0,0,0,0,0,Regular.
2: gui_qt_font_city_productions : Sans Serif,10,-1,5,50,1,0,0,0,0,Regular.
2: gui_qt_font_reqtree_text : Sans Serif,10,-1,5,50,1,0,0,0,0,Regular.
2: App default after change callbacks : Arial,14,-1,5,50,0,0,0,0,0,Regular.
2: Loading tileset "hexemplio".
2: Loading tileset "amplio2".
2: Drawing font for progress bar : Arial,14,-1,5,50,0,0,0,0,0,Regular.
2: Production combo itself : Arial,14,-1,5,50,0,0,0,0,0,Regular.
2: Production combo uses : Arial,14,-1,5,50,0,0,0,0,0,Regular.
2: Progress bar painter : Arial,14,-1,5,75,0,0,0,0,0,Regular.
2: Painter adjusted : Arial,8,-1,5,75,0,0,0,0,0,Regular.
2: Progress bar painter : Arial,8,-1,5,75,0,0,0,0,0,Regular.
2: last message repeated 2 times
2: last message repeated 2 times (total 4 repeats)

2022-06-26 04:45 Updated by: cazfi
Comentario

Reply To ddeanbrown

2: gui_qt_font_default : Arial,14,-1,5,50,0,0,0,0,0,Regular.

...

2: Progress bar painter : Arial,14,-1,5,75,0,0,0,0,0,Regular. 2: Painter adjusted : Arial,8,-1,5,75,0,0,0,0,0,Regular.

So, it's the adjustment done for the painter that makes the font smaller (14 -> 8). I already were looking at it for another problem in it.

2022-06-26 05:57 Updated by: cazfi
Comentario

Reply To cazfi

I already were looking at it for another problem in it.

Patch attached. See the commit message on top of it for details. It should make the adjustment to work more "right", but there's no guarantee that even right adjustment would be working well.

2022-06-26 13:11 Updated by: ddeanbrown
Comentario

New patch produces much better appearance. Still see the bug #44850 but that's a separate issue.

2022-07-05 00:16 Updated by: cazfi
  • Propietario Update from (Ninguno) to cazfi
  • Resolución Update from Ninguno to Accepted
  • Hito Update from (Ninguno) to 3.0.3 (cerrado)
2022-07-07 23:46 Updated by: cazfi
  • Estado Update from Open to Cerrado
  • Resolución Update from Accepted to Fixed

Editar

You are not logged in. I you are not logged in, your comment will be treated as an anonymous post. » Entrar