kh-fataoui / xdocreport

Automatically exported from code.google.com/p/xdocreport
0 stars 0 forks source link

html <sub> and <sup> tags in fields #484

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi  mr. Angelo!
Thank you for your xdocreport project, your library is very helpful for me.
I've got one problem.
I have text fields with html tags in my Data Base and I put them in my template 
fields.
I use FieldsMetadata to tell XdocReport that I wish use HTML syntax as it 
describles here 

https://code.google.com/p/xdocreport/wiki/DocxReportingJavaMainHTMLTextStyling 

FieldsMetadata metadata = report.createFieldsMetadata();
metadata.addFieldAsTextStyling("comments", SyntaxKind.Html);

It works fine – but, unfortunally, it does not supports <sub> and <sup> tags 
(superscript and subscript fonts) and I need them very mach.
I tried change   SyntaxKind to noEscape and replace <sub> tags to  <w:vertAlign 
w:val="superscript"/> but it conflicts with other tags. 

How do you think, is it any way to solve this problem?
I use XDocReport 1.0.4 version at Windows XP and OpenSuse 13.1 operation 
systems.
Thank you for any help. 

Original issue reported on code.google.com by StalAlex...@gmail.com on 17 Jun 2015 at 5:43

GoogleCodeExporter commented 9 years ago
At first please create your issues at 
https://github.com/opensagres/xdocreport/issues

> it does not supports <sub> and <sup> tags

As you can see 
https://github.com/opensagres/xdocreport/blob/master/document/fr.opensagres.xdoc
report.document.docx/src/main/java/fr/opensagres/xdocreport/document/docx/textst
yling/DocxDocumentHandler.java#L185 it doesn't support.

Any contribution are welcome!

Original comment by angelo.z...@gmail.com on 18 Jun 2015 at 7:13

GoogleCodeExporter commented 9 years ago
Hi,

For your information, I have created your issue at GitHub 
https://github.com/opensagres/xdocreport/issues/43

I have implemented <sub> and <sup> for docx. Please tell me if it works for you.

Original comment by angelo.z...@gmail.com on 18 Jun 2015 at 11:58

GoogleCodeExporter commented 9 years ago
Hi mr. Angelo!
It works fine, thank you very-very much!

P.S. For success deploying I had  to skip Maven test phase at  module 
fr.opensagres.xdocreport.remoting.reporting.server 

Original comment by StalAlex...@gmail.com on 22 Jun 2015 at 8:25