Skip to content

Commit

Permalink
0.3.8.7 (2022-03-05)
Browse files Browse the repository at this point in the history
+ Added support for different symbols on FOP rendered list (dash, minus,
letters, numbers)
  • Loading branch information
daneeldeveloper committed Mar 5, 2022
1 parent 2c7cc02 commit 13125f9
Show file tree
Hide file tree
Showing 18 changed files with 91 additions and 18 deletions.
4 changes: 2 additions & 2 deletions docgen/parameters.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"title" : "Venus (Fugerit Document Generation Framework)",
"name": "Venus",
"version" : "0.3.8.6",
"date" : "16/02/2022",
"version" : "0.3.8.7",
"date" : "05/03/2022",
"organization" : {
"name" : "Fugerit Org",
"url" : "https://www.fugerit.org"
Expand Down
6 changes: 5 additions & 1 deletion docgen/release-notes.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
0.3.8.5 / 0.3.8.6 (2022-02-16)
0.3.8.7 (2022-03-05)
--------------------
+ Added support for different symbols on FOP rendered list (dash, minus, letters, numbers)

0.3.8.5 / 0.3.8.6 (2022-02-16)
--------------------
+ Fix the current doc meta model supported version to 1.8

Expand Down
2 changes: 1 addition & 1 deletion fj-doc-base/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-base</name>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,8 @@ public DocElement getContent() {
return this.getElementList().get( 0 );
}

public boolean isContentList() {
return this.getContent().getClass().equals( DocList.class );
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,16 @@ public class DocList extends DocContainer {

public final static String LIST_TYPE_UL = "ul";

public final static String LIST_TYPE_ULD = "uld";

public final static String LIST_TYPE_ULM = "ulm";

public final static String LIST_TYPE_OL = "ol";

public final static String LIST_TYPE_OLN = "oln";

public final static String LIST_TYPE_OLL = "oll";

/**
*
*/
Expand All @@ -21,4 +29,17 @@ public void setListType(String listType) {
this.listType = listType;
}

/*
* Return canonical list type
*/
public String getClt() {
String clt = this.getListType();
if (clt.equalsIgnoreCase( LIST_TYPE_UL ) ) {
clt = LIST_TYPE_ULD;
} else if ( clt == null || clt.equalsIgnoreCase( LIST_TYPE_OL) ) {
clt = LIST_TYPE_OLN;
}
return clt;
}

}
12 changes: 11 additions & 1 deletion fj-doc-base/src/main/resources/config/doc-1-8.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
*
* @project : org.fugerit.java.doc.base
* @creation : 2021-12-22
* @version : 1.0.0 (2021-12-22)
* @version : 1.1.0 (2022-03-05)
*
* XSD for fugerit doc configuration
*/
Expand Down Expand Up @@ -297,8 +297,18 @@

<xsd:simpleType name="listType">
<xsd:restriction base="xsd:string">
<!-- default unordered list, same asd 'uld' -->
<xsd:enumeration value="ul"></xsd:enumeration>
<!-- unordered list, using dot -->
<xsd:enumeration value="uld"></xsd:enumeration>
<!-- unordered list, using minus -->
<xsd:enumeration value="ulm"></xsd:enumeration>
<!-- default ordered list, same asd 'oln' -->
<xsd:enumeration value="ol"></xsd:enumeration>
<!-- ordered list, using numbers -->
<xsd:enumeration value="oln"></xsd:enumeration>
<!-- ordered list, using letters -->
<xsd:enumeration value="oll"></xsd:enumeration>
</xsd:restriction>
</xsd:simpleType>

Expand Down
2 changes: 1 addition & 1 deletion fj-doc-ent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-ent</name>
Expand Down
2 changes: 1 addition & 1 deletion fj-doc-freemarker/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-freemarker</name>
Expand Down
2 changes: 1 addition & 1 deletion fj-doc-mod-fop/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-mod-fop</name>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@
<#list docList.elementList as li>
<fo:list-item>
<fo:list-item-label end-indent="label-end()">
<fo:block><fo:inline font-style="normal" <@handleFont element=li.content/>><#if docList.listType == 'ul'>&#183;<#else>${li?counter}.</#if></fo:inline></fo:block>
<fo:block><fo:inline font-style="normal" <@handleFont element=li.content/>><#if li.contentList><#elseif docList.clt == 'uld'>&#183;<#elseif docList.clt == 'ulm'>-<#elseif docList.clt == 'oll'>${li?counter?lower_abc}.<#else>${li?counter}.</#if></fo:inline></fo:block>
</fo:list-item-label>
<fo:list-item-body start-indent="body-start()">
<fo:block><#list li.elementList as element><@handleElement current=element/></#list></fo:block>
<fo:block><@handleElement current=li.content/></fo:block>
</fo:list-item-body>
</fo:list-item>
</#list>
Expand Down
2 changes: 1 addition & 1 deletion fj-doc-mod-itext/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-mod-itext</name>
Expand Down
2 changes: 1 addition & 1 deletion fj-doc-mod-jxl/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-mod-jxl</name>
Expand Down
2 changes: 1 addition & 1 deletion fj-doc-mod-pdfbox/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-mod-pdfbox</name>
Expand Down
2 changes: 1 addition & 1 deletion fj-doc-mod-poi/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-mod-poi</name>
Expand Down
2 changes: 1 addition & 1 deletion fj-doc-sample/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>
<version>0.3.8.6</version>
<version>0.3.8.7</version>
</parent>

<name>fj-doc-sample</name>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

public class TestXml01 extends DevHelper {

@Test
//@Test
public void test01() throws Exception {
Locale.setDefault( Locale.UK );
String testCase = "test-xml-01";
Expand All @@ -21,4 +21,16 @@ public void test01() throws Exception {
new File( BasicFacadeTest.BASIC_OUTPUT_PATH, testCase+"."+handler.getType() ), handler );
Assert.assertTrue( res );
}

@Test
public void test01Alt() throws Exception {
Locale.setDefault( Locale.UK );
String testCase = "test-xml-01";
DocTypeHandler handler = PdfFopTypeHandler.HANDLER;
boolean res = this.workerXmlToFoToPdf( new File( "src/test/resources/dev/"+testCase+".xml" ),
new File( BasicFacadeTest.BASIC_OUTPUT_PATH, testCase+".fo" ),
new File( BasicFacadeTest.BASIC_OUTPUT_PATH, testCase+"."+handler.getType() ) );
Assert.assertTrue( res );
}

}
24 changes: 23 additions & 1 deletion fj-doc-sample/src/test/resources/dev/test-xml-01.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,29 @@
<cell><para>King</para></cell>
</row>
</table>
<list list-type="ul">
<br/>
<list list-type="ulm">
<li><para>Element 1</para></li>
<li><para>Element 2</para></li>
<li>
<list list-type="ul">
<li><para>Element 2a</para></li>
<li><para>Element 2b</para></li>
<li>
<list list-type="ol">
<li><para>Element 2c1</para></li>
<li><para>Element 2c2</para></li>
</list>
</li>
<li>
<list list-type="oll">
<li><para>Element 2da</para></li>
<li><para>Element 2db</para></li>
</list>
</li>
</list>
</li>

</list>
<h head-level="2" align="center" id="b2">Header 2</h>
<para>sample normal text</para>
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<groupId>org.fugerit.java</groupId>
<artifactId>fj-doc</artifactId>

<version>0.3.8.6</version>
<version>0.3.8.7</version>
<packaging>pom</packaging>

<name>fj-doc</name>
Expand Down

0 comments on commit 13125f9

Please sign in to comment.