jakmeier / paddlers-browser-game

A multi-player real-time strategy browser game
Other
52 stars 3 forks source link

Text rendering incomplete #19

Closed jakmeier closed 3 years ago

jakmeier commented 4 years ago

Description

When texts are drawn to the window using FloatingText::write, the z-value and the fit strategy are ignored.

Example for Descend text which should be centered in both axis but isn't:

image

Implementation

Since the texts are styled with CSS, the solution for this issue is likely to be a combination of CSS and suitable extensions to the TextPool object defined in paddlers-frontend/src/view/text_pool.rs.

jakmeier commented 3 years ago

With the adoption of paddle as game engine, this has been fixed. The solution uses inline CSS on the text elements.