Back to index

scribus-ng  1.3.4.dfsg+svn20071115
style.h
Go to the documentation of this file.
00001 
00002 
00003 #ifndef STYLES_STYLE
00004 #define STYLES_STYLE
00005 
00006 #include "../style.h"
00007 #include "desaxe/digester.h"
00008 #include "desaxe/simple_actions.h"
00009 #include "desaxe/saxiohelper.h"
00010 
00011 
00012 using namespace desaxe;
00013 
00014 template<class SUBSTYLE>
00015 inline
00016 void  Style::desaxeRules(const Xml_string& prefixPattern, desaxe::Digester& ruleset, Xml_string elemtag)
00017 {
00018        Xml_string stylePrefix(Digester::concat(prefixPattern,elemtag));
00019        ruleset.addRule(stylePrefix, SetAttributeWithConversion<SUBSTYLE, const QString&>( & SUBSTYLE::setName, "name", &parse<const QString&>, QString::null));
00020        ruleset.addRule(stylePrefix, SetAttributeWithConversion<SUBSTYLE, const QString&>( & SUBSTYLE::setParent, "parent", &parse<const QString&>, QString::null));
00021        ruleset.addRule(stylePrefix, SetAttributeWithConversion<SUBSTYLE, const QString&>( & SUBSTYLE::setShortcut, "shortcut", &parse<const QString&>, QString::null));
00022 }
00023 
00024 #endif