X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;ds=sidebyside;f=org.argeo.cms%2Fsrc%2Forg%2Fargeo%2Fcms%2Ftext%2FTextSection.java;fp=org.argeo.cms%2Fsrc%2Forg%2Fargeo%2Fcms%2Ftext%2FTextSection.java;h=0000000000000000000000000000000000000000;hb=972528f4de2d00690362c01d3ce843ca9cd10250;hp=ac93e4b65cc116a4a38775d1a2be2cc1b320f9f8;hpb=c873a0359345503b8e3ca07828bd99d525ec7cc0;p=lgpl%2Fargeo-commons.git diff --git a/org.argeo.cms/src/org/argeo/cms/text/TextSection.java b/org.argeo.cms/src/org/argeo/cms/text/TextSection.java deleted file mode 100644 index ac93e4b65..000000000 --- a/org.argeo.cms/src/org/argeo/cms/text/TextSection.java +++ /dev/null @@ -1,52 +0,0 @@ -package org.argeo.cms.text; - -import javax.jcr.Node; -import javax.jcr.RepositoryException; - -import org.argeo.cms.CmsNames; -import org.argeo.cms.util.CmsUtils; -import org.argeo.cms.viewers.Section; -import org.eclipse.swt.widgets.Composite; - -public class TextSection extends Section implements CmsNames { - private static final long serialVersionUID = -8625209546243220689L; - private String defaultTextStyle = TextStyles.TEXT_DEFAULT; - private String titleStyle; - - public TextSection(Composite parent, int style, Node node) - throws RepositoryException { - this(parent, findSection(parent), style, node); - } - - public TextSection(TextSection section, int style, Node node) - throws RepositoryException { - this(section, section.getParentSection(), style, node); - } - - private TextSection(Composite parent, Section parentSection, int style, - Node node) throws RepositoryException { - super(parent, parentSection, style, node); - CmsUtils.style(this, TextStyles.TEXT_SECTION); - } - - public String getDefaultTextStyle() { - return defaultTextStyle; - } - - public String getTitleStyle() { - if (titleStyle != null) - return titleStyle; - // TODO make base H styles configurable - Integer relativeDepth = getRelativeDepth(); - return relativeDepth == 0 ? TextStyles.TEXT_TITLE : TextStyles.TEXT_H - + relativeDepth; - } - - public void setDefaultTextStyle(String defaultTextStyle) { - this.defaultTextStyle = defaultTextStyle; - } - - public void setTitleStyle(String titleStyle) { - this.titleStyle = titleStyle; - } -}