
com.github.czyzby.lml.parser.LmlStyleSheet Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gdx-lml Show documentation
Show all versions of gdx-lml Show documentation
Templates for LibGDX Scene2D UI with HTML-like syntax and FreeMarker-inspired macros.
package com.github.czyzby.lml.parser;
import com.badlogic.gdx.utils.ObjectMap;
/** Contains default values of attribute in tags.
*
* @author MJ */
public interface LmlStyleSheet {
/** @param tag name of the tag. Case might be ignored.
* @param attribute name of the attribute. Case might be ignored.
* @return default value for the chosen attribute or null if not set. */
String getStyle(String tag, String attribute);
/** @param tag name of the tag. Case might be ignored.
* @return map of tag's styles or null if none set. */
ObjectMap getStyles(String tag);
/** @param tag name of the tag. Case might be ignored.
* @param attribute name of the attribute. Case might be ignored.
* @param defaultValue will be the value of the chosen attribute in selected tags if it was not set already. */
void addStyle(String tag, String attribute, String defaultValue);
/** @param tag name of the tag. Case might be ignored.
* @param styles map of default attribute values mapped by their attribute names. Will be added.
* @see #addStyle(String, String, String) */
void addStyles(String tag, ObjectMap styles);
/** @param tag name of the tag. Case might be ignored.
* @param attribute name of the attribute. Case might be ignored. If any default value is assigned to the attribute,
* it will be removed. */
void removeStyle(String tag, String attribute);
/** @param tag name of the tag. Case might be ignored. All styles assigned to the tag will be removed. */
void removeStyles(String tag);
/** All stored styles will be removed. */
void clearStyles();
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy