[xwiki-devs] [XAOFFICE] [Proposal] Should we respect style / font attributes when importing office documents ?
Hi Devs, When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example : <p class="western">Text in a <sup><span style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p> And finally when this is transformed into xwiki syntax, the result will look something like : (% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent). So, there are three options : 1. Rip off style information. 2. Keep style information as it is. 3. Give the user an option to select between 1 and 2. I'm going with 3. :) WDYT ? Thanks. - Asiri [image: Asiri Rathnayake's Facebook profile]<http://www.facebook.com/people/Asiri_Rathnayake/534607921>
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p>
And finally when this is transformed into xwiki syntax, the result will look something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
+1
I'm going with 3. :)
WDYT ?
Thanks.
- Asiri
[image: Asiri Rathnayake's Facebook profile]<http://www.facebook.com/people/Asiri_Rathnayake/534607921> _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
+1 for 3 On Mon, Nov 3, 2008 at 1:13 PM, Asiri Rathnayake <[email protected]> wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p>
And finally when this is transformed into xwiki syntax, the result will look something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
WDYT ?
Thanks.
- Asiri
[image: Asiri Rathnayake's Facebook profile]<http://www.facebook.com/people/Asiri_Rathnayake/534607921> _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Thomas Mortagne
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p>
And finally when this is transformed into xwiki syntax, the result will look something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
-- Sergiu Dumitriu http://purl.org/net/sergiu/
Hi, On Mon, Nov 3, 2008 at 2:26 PM, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span
style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p>
And finally when this is transformed into xwiki syntax, the result will
look
something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
I'd be in favour of removing parameters that do not directly translate into XWiki 2.0 syntax items in all cases (otherwise imported documents will not have a consistent look across the wiki). This would mean getting rid of font size, font color and font family in all cases, without even allowing the user to do so. WDYT? Guillaume
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
-- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Guillaume Lerouge Product Manager - XWiki Skype ID : wikibc http://blog.xwiki.com/
Guillaume Lerouge wrote:
Hi,
On Mon, Nov 3, 2008 at 2:26 PM, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed
into
xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span
style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p>
And finally when this is transformed into xwiki syntax, the result will
look
something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki
mode.
And another argument is that content is more important than style
(vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
We should at least keep the font size or convert it to the closest heading.
I'd be in favour of removing parameters that do not directly translate into XWiki 2.0 syntax items in all cases (otherwise imported documents will not have a consistent look across the wiki). This would mean getting rid of font size, font color and font family in all cases, without even allowing the user to do so.
This is how XWord behaves right now and IMO it can be quite disturbing for the user to see big differences between the original document and the wiki layout. XWord will use OfficeImporter for some of it's features and I prefer to be able to choose between keeping the style data and not keeping it. Here's my +1 for 3.
WDYT?
Guillaume
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
-- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
On Nov 3, 2008, at 3:33 PM, Guillaume Lerouge wrote:
Hi,
On Mon, Nov 3, 2008 at 2:26 PM, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span
style="color:;font-family=;font-size=2pt;">superscript</span></ sup>format</p>
And finally when this is transformed into xwiki syntax, the result will
look
something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
I'd be in favour of removing parameters that do not directly translate into XWiki 2.0 syntax items in all cases (otherwise imported documents will not have a consistent look across the wiki).
The (%...%) notation *IS* wiki syntax. I think you're talking about removing style elements.
This would mean getting rid of font size, font color and font family in all cases, without even allowing the user to do so.
Without allowing the user to do what? Thanks -Vincent
WDYT?
Guillaume
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
On Mon, Nov 3, 2008 at 9:15 PM, Vincent Massol <[email protected]> wrote:
On Nov 3, 2008, at 3:33 PM, Guillaume Lerouge wrote:
Hi,
On Mon, Nov 3, 2008 at 2:26 PM, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span
style="color:;font-family=;font-size=2pt;">superscript</span></ sup>format</p>
And finally when this is transformed into xwiki syntax, the result will
look
something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
I'd be in favour of removing parameters that do not directly translate into XWiki 2.0 syntax items in all cases (otherwise imported documents will not have a consistent look across the wiki).
The (%...%) notation *IS* wiki syntax. I think you're talking about removing style elements.
I know that (%...%) is wiki syntax. What I meant is that I agreed with Asiri on the fact that an user will never bother editing a document loaded with (%...%) all over the place. Thus removing style elements by default (and therefore avoiding having to use the (%...%) syntax as a byproduct) seems to be the best option to me.
This would mean getting rid of font size, font color and font family in all cases, without even allowing the user to do so.
Without allowing the user to do what?
Without letting the user import styles by default (ie, the user should explicitely choose importing styles). Guillaume
Thanks -Vincent
WDYT?
Guillaume
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Guillaume Lerouge Product Manager - XWiki Skype ID : wikibc http://blog.xwiki.com/
On Mon, Nov 3, 2008 at 2:26 PM, Sergiu Dumitriu <[email protected]> wrote:
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
+1
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
+1 for 3) if the default is set to "rip off syntax info that is not handled by wiki markup".
On Nov 3, 2008, at 4:18 PM, Jean-Vincent Drean wrote:
On Mon, Nov 3, 2008 at 2:26 PM, Sergiu Dumitriu <[email protected]> wrote:
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
+1
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
+1 for 3) if the default is set to "rip off syntax info that is not handled by wiki markup".
Not sure what you mean by this. I'd much prefer that the default be to import only content and not style. Thanks -Vincent
On Mon, Nov 3, 2008 at 2:26 PM, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p>
And finally when this is transformed into xwiki syntax, the result will look something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
+1
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
-- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
-- Thomas Mortagne
Hi Sergiu, All, On Mon, Nov 3, 2008 at 6:56 PM, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span
style="color:;font-family=;font-size=2pt;">superscript</span></sup>format</p>
And finally when this is transformed into xwiki syntax, the result will
look
something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
Where can I find the legal style elements that can be rendered in xwiki 2.0 ? I mean like text-align, color and so and so ? If we have such a comprehensive list, then we can simply rip off everything else! I mean, what is not possible to be rendered should not be kept ... In this case, I don't see a requirement of presenting a choice to the user, isn't it ? Thanks. - Asiri
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
-- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs
On Nov 4, 2008, at 7:32 AM, Asiri Rathnayake wrote:
Hi Sergiu, All,
On Mon, Nov 3, 2008 at 6:56 PM, Sergiu Dumitriu <[email protected]> wrote:
Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span
style="color:;font-family=;font-size=2pt;">superscript</span></ sup>format</p>
And finally when this is transformed into xwiki syntax, the result will
look
something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
What is expressible with wiki markup should be kept (headings, bold, superscript...). No font information, please.
Where can I find the legal style elements that can be rendered in xwiki 2.0 ?
They are all legal. Not sure what you mean. Whatever is legal in XHTML is legal.
I mean like text-align, color and so and so ?
If we have such a comprehensive list, then we can simply rip off everything else! I mean, what is not possible to be rendered should not be kept ...
As I said you can remove all style attributes.
In this case, I don't see a requirement of presenting a choice to the user, isn't it ?
The user should be able to choose whether he wants to import styles or not. Thanks -Vincent
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
+1 for 3.
WDYT ?
Thanks.
- Asiri
+1 for 3 with the default being not to import styles. Thanks -Vincent On Nov 3, 2008, at 1:13 PM, Asiri Rathnayake wrote:
Hi Devs,
When converting office documents into html (before they are transformed into xwiki syntax) lots of style information gets added into the html. For an example :
<p class="western">Text in a <sup><span style="color:;font-family=;font-size=2pt;">superscript</span></ sup>format</p>
And finally when this is transformed into xwiki syntax, the result will look something like :
(% class="western" %) Text in a ^^(% style="color:;font-family=;font-size=2pt;" %)superscript^^(%%) format
The problem with this is, the resulting xwiki document will have lot's of (%%) elements which makes it difficult to make modifications in wiki mode. And another argument is that content is more important than style (vincent).
So, there are three options :
1. Rip off style information.
2. Keep style information as it is.
3. Give the user an option to select between 1 and 2.
I'm going with 3. :)
WDYT ?
Thanks.
- Asiri
participants (8)
-
Asiri Rathnayake -
Florin Ciubotaru -
Guillaume Lerouge -
Jean-Vincent Drean -
Marius Dumitru Florea -
Sergiu Dumitriu -
Thomas Mortagne -
Vincent Massol