mirror of
https://github.com/SpartanJ/eepp.git
synced 2026-10-01 18:50:16 +03:00
Fix two list-marker issues:
- Decimal/text markers now inherit the current list-item font color. - Marker X/Y coordinates are pixel-snapped, eliminating blurry rendering. - The behavior is shared by <li> and textual <summary> markers. - Added focused tests for inherited color and integer positioning.
This commit is contained in:
@@ -6,6 +6,10 @@
|
||||
#include <eepp/math/rect.hpp>
|
||||
#include <eepp/ui/csslayouttypes.hpp>
|
||||
|
||||
namespace EE { namespace Graphics {
|
||||
class Text;
|
||||
}} // namespace EE::Graphics
|
||||
|
||||
namespace EE { namespace UI {
|
||||
|
||||
class EE_API UIHTMLListStyle {
|
||||
@@ -16,6 +20,11 @@ class EE_API UIHTMLListStyle {
|
||||
|
||||
static String getTextMarkerString( CSSListStyleType type, int index );
|
||||
|
||||
static void syncTextMarkerColor( Graphics::Text& marker, const Color& color );
|
||||
|
||||
static Vector2f getTextMarkerPosition( const Vector2f& screenPos, const Rectf& paddingPx,
|
||||
Float textWidth, Float fontSize );
|
||||
|
||||
static void drawPrimitiveMarker( CSSListStyleType type, const Vector2f& screenPos,
|
||||
const Rectf& paddingPx,
|
||||
const Graphics::FontStyleConfig& style );
|
||||
|
||||
Reference in New Issue
Block a user