From c0b08b4f091641f70df0f5104f52c56ca360cc63 Mon Sep 17 00:00:00 2001 From: Tavmjong Bah Date: Thu, 7 Jun 2018 11:44:33 +0200 Subject: Add GUI support for 'font-variant-east-asian' property. --- src/style-internal.h | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) (limited to 'src/style-internal.h') diff --git a/src/style-internal.h b/src/style-internal.h index 0ca9b0445..7d2b3a89b 100644 --- a/src/style-internal.h +++ b/src/style-internal.h @@ -9,7 +9,7 @@ * Jon A. Cruz * Tavmjong Bah * - * Copyright (C) 2014 Tavmjong Bah + * Copyright (C) 2014, 2018 Tavmjong Bah * Copyright (C) 2010 Jon A. Cruz * Copyright (C) 2001-2002 Lauris Kaplinski * Copyright (C) 2001 Ximian, Inc. @@ -689,6 +689,30 @@ public: }; +/// SPIEnum w/ extra bits. The 'font-variants-east-asian' property is a complete mess that needs +/// special handling. Multiple key words can be specified, some exclusive of others. +class SPIEastAsian : public SPIEnum +{ + +public: + SPIEastAsian() : + SPIEnum( "anonymous_enumeastasian", NULL ) + {} + + SPIEastAsian( Glib::ustring const &name, SPStyleEnum const *enums) : + SPIEnum( name, enums, SP_CSS_FONT_VARIANT_EAST_ASIAN_NORMAL ) + {} + + virtual ~SPIEastAsian() + {} + + virtual void read( gchar const *str ); + virtual const Glib::ustring write( guint const flags = SP_STYLE_FLAG_IFSET, + SPStyleSrc const &style_src_req = SP_STYLE_SRC_STYLE_PROP, + SPIBase const *const base = NULL ) const; +}; + + /// String type internal to SPStyle. // Used for 'marker', ..., 'font', 'font-family', 'inkscape-font-specification' class SPIString : public SPIBase -- cgit v1.2.3