On 12/08/2010 04:32 PM, Marius Dumitru Florea wrote: > Hi devs, > > When importing an office document using the "Add> Page from Office" > menu the page title is given by > org.xwiki.officeimporter.document.XDOMOfficeDocument#getTitle() which > looks for the first heading (org.xwiki.rendering.block.HeaderBlock) in > the document content. > > This is fine most of the time, but if the title of the office document > is not set using heading style (e.g. a custom defined style is used > instead) then: > > (1) The page title is wrong. > (2) The first heading is hidden because it equals the page title. This > is very bad when there is text before the first heading. > > WDYT about modifying XDOMOfficeDocument#getTitle() to take into account > the first paragraph also when looking for the page title?
What happens if the document contains a header, like a date, time, address, company name, stuff like that, won't this break things even more, since all documents will be called "Finance Department, BigCompany, 42 Main Street"? > Note that I have many Word documents with this problem so fixing them to > use heading style for their titles is not a good option for me. -- Sergiu Dumitriu http://purl.org/net/sergiu/ _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs

