Development: Difference between revisions
m (remove spam) |
No edit summary |
||
Line 608: | Line 608: | ||
* [[XSLT Export to MSProject|XSLT export to MSProject 2003 XML format]] | * [[XSLT Export to MSProject|XSLT export to MSProject 2003 XML format]] | ||
[http://www.ez-agents.com/pocket_bike/scooters-wholesale.asp scooter wholesale, wholesale scooter, scooter manufacturer, wholesale moped, scooter supplier][http://www.ez-agents.com/pocket_bike/wholesaleatv.asp wholesale atv, atv wholesale, atv manufacturer, atv import, atv factory] | |||
[http://www.ez-agents.com/pocket_bike/gas-generators.asp generator wholesale, generator manufacturer, wholesale generators, generator supplier] | |||
[http://www.ez-agents.com/pocket_bike/wholesale-massage-chairs.asp#vending vending massage chairs, wholesale massage chairs, massage chair import][http://www.ez-agents.com/pocket_bike/wholesalefurniture.asp wholesale furniture, furniture manufacturer, wholesale leather sofa sets, furniture manufacturer][http://www.ez-agents.com/pocket_bike/vending_machines.asp vending machines, china vending machine, vending machine manufacturers, vending machine bulk, maquina vending ] |
Revision as of 19:13, 4 January 2007
The development of FreeMind is coordinated using FreeMind's project page at SourceForge, and also using this wiki. At wiki, we have requests for enhancements page; there is also requests for enhancements (RFEs) page at SourceForge (not preferred). You can browse CVS repository. We also use SourceForge for bugs, and open discussion forum. We do not use the documentation part there as we use this wiki instead. Getting started as a developer or testerTo get the latest beta version of FreeMindYou can get the beta version from the CVS. Look under branches. Observe, that these versions are not official releases and may admit serious errors. Please, use them only if you urgently need a feature included in such a version or to give us feedback to our development which is highly appreciated. To compile FreeMind on your ownIf you are a developer, just download the sources, unpack them,
find the folder with the file build.xml, and execute the command
Broken down into simple steps, a simple way for a developer of compiling FreeMind is perhaps the following.
To set up a FreeMind project under EclipseYou download FreeMind to ~/src/freemind say. Then, you have to compile FreeMind on command line using "ant dist". After that you open a new project with working directory ~/src you should find the following settings:
Then finish the project settings and there should be no errors in the project. You can run FreeMind starting the class Further development wiki pagesFurther reading (still under construction):
To use concurrent version repository (CVS) with EclipseSee Using CVS from within Eclipse guide by Bob Alexander. When working with CVS, remember that it is difficult to change directory and file names under CVS. Moreover, it not easy to remove files completely. Therefore, pay attention when checking files in. Becoming a developerNew developer starts by sending his contributions as patches. Later on, he may get access to CVS repository. The process is approximately as follows.
Development resources
Getting the latest CVS branchThe latest integration branch is fm_060405_integration. The last release has tag FM-0-8-0. How the FreeMind development is organizedInitially every active developer works on his own branch. Our intermediate results are published as our "alpha versions". We use forum Open Discussion and section Experimental_versions on this wiki page to communicate them. Only after this partial developments are finished, they can me merged together. The resulting version is expected to work with all maps created by all versions, which are merged into it, but we can not assure it in any particular case. The merged versions are published as Release Candidates and are released. An alternative to this development scheme would be not to publish the intermediate versions, and I think the current method is probably a better one. Experimental versionsCurrently, there are the following experimental versions available. They are not meant for productive use; use at your own risk! FreeMind with Node Attributes and Map FiltersAttaching of named attributes to every node, filtering of the displayed map content based on node text, node icons and node attributes FreeMind with WYSIWYG rich text node editorFreeMind Browser Applet for FreeMind 0.8Alpha, Beta and Release CandidateI propose the following definitions of labels alpha, beta, and release candidate.
--Danielpolansky 04:49, 29 Apr 2006 (PDT) Conceptual remarksModular model - view designThe architecture of FreeMind makes it possible that FreeMind becomes general tool for editing tree-structured data, that is mind maps, XML/HTML documents, folder trees etc. in future. All these kinds of data would be presented to the user as a mind map. Model-View-Controller design makes it possible for you only to write so called model of the data structure, without caring for the visual representation. Currently, mind map mode and file mode are implemented. Original vision of Joerg MuellerJoerg Muller is the original author of FreeMind, developing it up to the version 0.4.0. Here follows what he's got to say on his original vision:
One may think of extending FreeMind to work with networks as opposed to trees only, an example of this being Topic Maps (ISO). Daniel Polansky: Joerg's vision of FreeMind becoming Emacs for tree data is intriguing, but rather far fetched at the time. You would need to provide scripting facility and at least many basic operations, like upcase, downcase, replace and many others. It is even not evident that this goal valuable compared to other goals - there many quite obvious and still missing features. Why not use OPML for storage instead of FreeMind's native XML formatThe current version of OPML is not suited for our purposes. It should be easy to create conversion XSLT between FreeMind and OPML. First, if we decided to use OPML, we would have to wait until the owner of OPML changes his standard to fit our needs. Thus, we would be dependent, not being able to act dynamically. Second, already the current version of OPML is insufficient. It does not contain most of what FreeMind already uses: colors, fonts, folded tag, edges and icons. It is not a superset of FreeMind's XML format, even not in a vague sense. Even if I renamed the elements names properly, OPML would still be a subset and not superset of FreeMind's XML. As a result, we have no benefit from using OPML right now. Summary: 1) we would run into dependence, and 2) OPML is insufficient, loosely speaking it is a subset. Why may FreeMind be more relevant than some other open source applicationsThere are many efforts to create new text editors, text processor and the like. While this activity is not without value, it does not fill that big value gap as mind mapping application. Take, for instance, text editors like JEdit. There are already well estabilished text editors like Emacs or Vim, and there are many others. It's not that these editors would be perfect, far from that, but they're still pretty useful and with some training users can become very efficient with them. With text processors, the thing is that most users in companies have already Microsoft Office for free. What does that mean? That means that the individual users do not have to pay for the MS Office, and they cannot effectively decide to use other Office platform either because of the value of easy sharing. Furthermore, there are competing free Office platforms like KOffice, OpenOffice or AbiWord. In mind mapping, the situation is quite different. You do not get commercial alternative granted in companies, unlike office applications. The point here is that most of MS Windows users, the mainstream, do not have a mind mapping application yet. For them, starting to use FreeMind is not a switch from Microsoft product to alternative product. It is a switch from scattered documents in incomparable and hard-to-overview formats to one document with unprecedented order and transparency - FreeMind's mind map. Therefore, I am expecting a growth of interest of free developers in developing and using this application. Furthermore, even though Java is quite slow and memory hungry, it solves the neverending quarrel between religious die-hard fans of different computing platforms, which I have first experienced with Atari 800 XL versus Commodore 64 battle, later IBM compatible versus Commodore Amiga battle, and nowadays Windows versus Linux battles. MiscTo create a new releaseTo succesfully complete a new release, do the following
Notice that the news cannot be monitored unlike forum, and forum has no RSS feed unlike news. To create proper copyright noticeA source file may be viewed as a sum b + d1 + d2 + ... + dk, where b is the basis, di are deltas (or patches), and the plus operator is the operator of applying a patch. The basis and each delta have their own copyright holder and the year of copyright. If there is only one autor and one year, then the copyright notice is simple. If there is only one autor and more years, then the copyright notice may look like
which is to be understood as
If there are more authors, then the copyright notice consists of more lines, like
Not all changes are eligible for copyright. If a change is small, then it does not make sense to add a line to the copyright notice for it. Copyright notice is not required for copyright to hold. It makes claiming your right at court easier. The correctness of these instructions is not granted. They are subject to improvement as we see fit. --Danielpolansky 11:29, 3 Jun 2005 (PDT) All on keyboard mappingsCurrently, each function has at most one key assigned. But, it should be the other way around; the keys should have functions assigned, rather than functions key. For instance, it would be valuable to have both insert and tab assigned to new node function. (Actually on MS Windows it is right now not possible at all to bind anything to tab.) To translate FreeMind into your languageLook for a translation into your language present in the development branch. If such a translation isn't present, take the latest revision of Resources_en.properties. Translate the labels in the text at the right side from = to your language. You can directly create and edit any java property file in any language using propedit.
Another interesting tool to manage language property files is popeye. Popeye can deal with several language property files at the same time so you can contrast the original property file data with their translations. Also, the program can highlight all properties that do not have a translation set in one of the selected languages. Alternatively you can save your property file in UTF-8 encoding; this is possible e.g. using Microsoft Notepad. After that convert the file into \uXXXX Unicode escape notation, using native2ascii tool included with the Java SDK. Example of use (Resources_cs.properties.txt is before conversion): cd C:\j2sdk1.4.2\bin> native2ascii.exe -encoding UTF8 Resources_cs.properties.utf8.txt Resources_cs.properties Ideally, your file's name will be Resources_xx.properties, where xx is the code of the language (e.g. en, de, dk etc.). Send your translation as a patch afterwards. To convert \uXXXX Unicode encoded file back to UTF-8, use a command similar to the following. cd C:\j2sdk1.4.2\bin> native2ascii.exe -reverse -encoding UTF8 Resources_cs.properties Resources_cs.properties.utf8.txt Currently, we have the following languages translated.
To activate a new translation, follow the following steps:
To translate the wiki pages itselfSee [1] for a description of how to do that. We don't have such a page yet, so, please, be careful. FreeMind's xml data format (.mm)FreeMind stores his data in own XML flavor. Up to FreeMind 0.6.5, the xml format has been unchanged. The list of elements and their attributes as of FreeMind 0.7.1 follows.
The actual W3C schema can be found under [[2]]. Libraries and tools used in FreeMindSources of free iconsFreeMind uses (a) tool icons used in the toolbars, and (b) icons used in nodes. Especially for the icons used in nodes, a good comprehensive source of free icons is needed. FreeMind uses PNG icons, in the size of 16 x 16. Nowadays many icons are drawn in SVG vector format first, and converted to 16 x 16 bitmap images afterwards. Ideally, it would not be the task of FreeMind team to draw icons; this task should be outsourced instead. Whether this is a realistic assumption remains to be seen. Some links on the sources of free icons follow.
ImplementationMenu Label Checklist
To implement embedded imagesTo implement embedded images, one would store binary data in a node, like <node TYPE="image" BINARY="x4543edvc...45ert"/> Upon opening the node for viewing, temporary file would be created and HTML viewer would point to that file. Upon editing, external image editor would be opened to edit the temporary file, like Gimp. Improved HTML editingFreeMind's long node may contain HTML. However, it needs to be edited in its source text form. We can improve upon that by
Open Source WYSIWYG HTML editors in JavaThere are the following open source WYSIWYG HTML editors written in Java.
Using HTML versus XHTML in rich text nodesWhat follows is a preliminary analysis of the issues concerning HTML versus XHTML used for rich text in FreeMind. AFAIK there are two separate questions: (1) should we store (a) HTML or (b) XHTML in nodes, and (2) should we (a) store only one thing or (b) store plain text in one attribute, and store HTML/XHTML in another attribute where HTML is available, modelling on email systems. As for the first question, using HTML has the advantage of being straightforward: it is supported by JLabel, it is supported by Java HTML editing component, and it is the format now mostly used in web pages. An advantage of XHTML is that it is a flavor of XML and thus easily amenable to XSLT processing. As for the second question, as soon as we would store also plain text, it would be automatically available to all XSLT processing, which would make the first question less decisive. However, it would considerably increase the size of mind maps stored on the disk, by my estimation by factor 1.5 as soon as a lot of rich text would be used. Performing transformations of HTML to XHTML on the fly before performing preprocessing from FreeMind would not really save the day, as XHTML would still need to be stored in mind maps on the disk; if we would use HTML internally, we would have to convert XHTML to HTML upon loading a new map for all nodes, instead of doing that only upon nodes being shown for the purpose of JLabel. If you find the other options more attractive, an important question is: is it really possible to process XHTML from within an XML attribute? Can someone demonstrate that? If yes, that would make XHTML rather attractive. But if not really, then using HTML would be as good as using XHTML. Converting HTML from node attribute TEXT to plain text within XSLTConverting HTML from node attribute TEXT to plain text within XSLT is virtually impossible. XSLT does not feature regular replaces, and it does not even feature simple text replaces (simple text replaces can be sort of implemented within XSLT though). My old view on this option follows.
Storing XHTML on par with FreeMind XMLThe option of storing XHTML elements on par with FreeMind XML elements like <node> would require a considerable effort. The benefits of the effort would include
The costs would include
By storing on par, I mean the following. <map> <node> <html> <body>Hello </br> Dolly.</body> </html> </node> </map> I recommend to avoid this option. Out current option is <map> <node TEXT="& lt ; HTML & gt ; Hello & lt ; br & gt ; Dolly."/> </map> A discussion shows the following possibilities of storing on par.
Converting HTML to XHTML in JavaI find a conversion of HTML to XHTML possible with reasonable effort. I think there are not many more subtleties apart from those already addressed: closed tags < td >, < tr > and the like, closed tags < /br >, < /hr >, < img/ > and several others. We would be able to discover all the subtleties by reading XHTML standard and by empirical testing. (For reference, html2xhtml at shredzone.net, thanks to Dimitri) However, W3C points out that converting HTML to XHTML is a tricky business.
See also Convert HTML content to PDF format at JavaWorld using JTidy. Converting XHTML to HTML in JavaSearching the web using the expressions
I have found very little about already existing code for converting XHTML to HTML in Java, with GNU GPL licenced code. Thus, my recommendation is to create a new method for that, in the class Tools. The method would be created with the use of [1] as a checklist. The method would use regular expression replaces, unless we see that this is too slow, which I do not think will be the case. (We already use regular expression replaces in method update() of NodeView.) A preliminary code is as follows. public String xhtmlToHtml(String xhtmlText) { //Remove '/' from <.../> of elements that do not have '/' there in HTML return xhtmlText. replaceAll("<(("+ "br|area|base|basefont|"+ "bgsound|button|col|colgroup|embed|hr"+ "|img|input|isindex|keygen|link|meta"+ "|object|plaintext|spacer|wbr"+ ")(\\s[^>]*)?)/>", "<$1>")); See also
Requirements on file format of FreeMindWe have identified the following requirements on the format of FreeMind. These have different priority; people may disagree about what the priority of their requirements are.
For Danielpolansky, the requirement on staying reasonably backwards compatible is important; the requirement on the solution to be fast too; the requirement on XSLT transformations is completely unimportant in view of the possibility of replacing XSLT transformations with small Java functions doing the same with less footprint; the requirement on keeping the format simple is important; the requirement on making it easy to create mind maps programatically is important. Sources of HTML coming to mind mapsRich text in the form of HTML will be coming into FreeMind from the following sources:
To my experience, the pasting is much more usual and of higher volume than direct editing. See also
--Danielpolansky 03:29, 29 Apr 2006 (PDT) Rendering of HTML nodes is slowRendering of quite long HTML nodes is slow. If you have a HTML page corresponding to ten paper pages, then the rendering of the node upon unfolding takes several seconds. The related code is in the method setText(nodeText); in the section if (nodeText.startsWith("<html>")) { // Make it possible to use relative img references in HTML using tag <base>. if (nodeText.indexOf("<img")>=0 && nodeText.indexOf("<base ") < 0 ) { try { nodeText = "<html><base href=\""+ map.getModel().getURL()+"\">"+nodeText.substring(6); } catch (MalformedURLException e) {} } setText(nodeText); This result does not give us much hope of improving the speed easily, as the command just tells Java's JLabel to render the page. A solution would be to find a different HTML rendering Java component. We can also wait until Sun's Java virtual machine improves the speed of JLabel's HTML rendering. -- What about pre-loading nodes which are likely to be expanded, using threading? Keep some relatively small cache of nodes in proximity to the last expanded node, and swap in the expanded node when the unexpanded one is clicked. No? To obtain focus for selected node in reliable mannerRequesting focus for NodeView using requestFocus() method is unreliable. A reliable way of doing that has been implemented in the method getController().obtainFocusForSelected(); Requesting focus using newSelected.requestFocus(); where To set the class load path in manifest.mf in jarIn the source folder tree of FreeMind, there's a file MANIFEST.MF. This file tells what should happen with the freemind.jar when java tries to run the jar archive. The file may look like Manifest-Version: 1.0 Main-Class: freemind.main.FreeMind Class-Path: silk.jar nanoxml.jar ekit.jar kafenio.jar kafenio-config.jar kafenio-icons.jar gnu-regexp-1.1.4.jar Created-By: Joerg Mueller A tricky thing about the file is that the length of the lines can be at most 72 characters. That creates difficulties when specifying Class-Path. In the exaple above, the first line of Class-Path is set in such a way that it has 70 chacters. That has been achieved by putting spaces before the actual list of classes. In the freemind.jar, the file can be found in the folder META-INF. Here you can check if the manifest has been created correctly. Deleting nodes and branches in FreeMindSince version 0.8.0, it is possible to delete a whole branch of nodes by pressing DELETE. When a user accidentally presses DELETE and does not notice that, they may loose considerable amount of data. For users using FreeMind as a knowledge base or a semi-structured database, being able to delete whole branch at one keystroke is problematic and unusual; in filesystem browsers, users are asked for confirmation before the file is deleted by the system. However, some users use FreeMind as a mind mapper and are glad to be able to delete nodes just by pressing DELETE. There are several solutions to this problem.
The confirmation would be requested both for keystrokes DELETE and CONTROL + X, that is the actions Delete and Cut. More development pagesDocumentation effortsSee documentation efforts. Also, internals documentation at Under the covers. Short patchesSee short patches. Community developmentscooter wholesale, wholesale scooter, scooter manufacturer, wholesale moped, scooter supplierwholesale atv, atv wholesale, atv manufacturer, atv import, atv factory generator wholesale, generator manufacturer, wholesale generators, generator supplier
vending massage chairs, wholesale massage chairs, massage chair importwholesale furniture, furniture manufacturer, wholesale leather sofa sets, furniture manufacturervending machines, china vending machine, vending machine manufacturers, vending machine bulk, maquina vending |