This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
My primary requirement is customizable XML formatting. <please add your own in followups> These is one project matching all known requirements http://sourceforge.net/projects/jtidy/ Jtidy can be moreover utilized for HTML->XHTML conversions.
Tor would you mind to take care of it?
Ian is an expert on third party code processes and evaluation. Ian, Tor already posted a LFI request at nbdiscuss.
Not only that, I've filled out the Sun legal forms for this too so it's all in Ian's hands.
From: Tor Norbye <torbjorn.norbye@sun.com> To: nbdiscuss@netbeans.org Subject: [nbdiscuss] JTidy (was: Gimme an LFI # ...) Date: 28 Mar 2003 16:25:13 -0800 Re: JTidy integration: the LFI process roundtrip time was 8 weeks. On Thu, 2003-01-30 at 02:07, Petr Kuzel wrote: > Tor, once approved, could you place it under libs project, please?. > XML modules could share it for formatting and pretty printing > features. I don't have commit privileges to libs - can you do it? The scrambled version is available in tasklist/html/external/. We should consider sharing more than the lib. The tasklist module already has a class (ReportWriter) which accumulates JTidy errors into method calls (instead of it getting dumped to stdout/stderr), and it also has an action (RewriteAction) which lets you reformat (and clean up) an HTML/JSP/XHTML document. Note that this does not just apply to XML files, it applies to HTML files and JSPs as well. So I think it would be wrong to duplicate/move the code to the XML modules; instead it makes sense to have a "jtidy" module which provides this functionality. Then the tasklist module can have a simple bridge module which simply hooks the JTidy output into the suggestions functionality, and if you have some specific needs for XML that don't apply to HTML or JSPs, those can go in the XML bridge module. Does that make sense? -- Tor P.S. To try this, get the latest tasklist/html module with the suggestions functionality (possibly available on the update center soon, and definitely from the tasklist.netbeans.org downloads section) and then open an HTML or XML document - then look in the Tools menu for "JTidy: Clean up & Format...". It uses the diff module as well to give you a before & after preview of the cleanup operation.
Tor, I granted you the developer role in the libs project. Adding extras to wrapper library make sense because their lifetime is tied with the library lifetime. But please keep dependencies close to zero. Clients that are not interested in extras should not pay for their presence.
I can add the jtidy library itself to libs. But I don't think you addressed my main point: JTidy functionality is desirable for html, jsp, and XML. If I just expose it as a library, then the XML module, and the HTML module, and the JSP module, might all add a NetBeans action "Clean up with JTidy". They might also all have option panels in the Options GUI, etc. etc. Seems to me we should instead have a "Tidy" NetBeans module. This module when present provides a formatting action that gets enabled whenever the current node is capable of getting formatted by JTidy. Unfortunately I have approximately zero time to work on this. So the only thing I can commit to doing is adding the jtidy binary into the libs external package, but as I mentioned that will probably result in a technology that is implementation/architecture driven, not user interface driven. And also, the tasklist/html module provides some useful functionality on top of jtidy; I'm not sure if you're advocating that should go into the "library" (I don't often think of e.g. NetBeans actions as library-material) but if it's not shared, there will be unnecessary code duplication (and worse yet, UI inconsistency. E.g. the reformat action chosen by HTML might offer a different preview/diff functionality than the one offered by the XML module.)
> But I don't think you addressed my main point: JTidy functionality > is desirable for html, jsp, and XML. If I just expose it as > a library, then the XML module, and the HTML module, and the JSP > module, might all add a NetBeans action "Clean up with JTidy". That's how I see it. > They might also all have option panels in the Options GUI, etc. etc. Currently it's up to module authors whether they share some settings or not. Introducing Tidy module does solve it only for one class of modules. UI consistency problem must be adressed at another level. E.g. indentation settings should be shared by all text editors by default.
It lives under tasklist/extrenal/Tidy-r7.jar.scrambled. Nobody seems to be working on moving it to libs...
What has happened to this feature? I was really looking forward to being able to tidy up my XML and HTML? Thanks, Meg