Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

Script in Freemind

Help
Rochat Luc
2009-03-19
2013-04-11
  • Rochat Luc
    Rochat Luc
    2009-03-19

    Hello,
    Is there some documentation on the scripts in FreeMind ?

    Thank's

    Luc

     
    • Rochat Luc
      Rochat Luc
      2009-03-21

      I would replace a string by another within my file (an absolute address by a relativ) ; but I have'nt find a command "replace" in the menu "Edit" .
      So, I will try to make this myself.
      Thank's for the ideas.
      Luc

       
  • Johny B
    Johny B
    2010-08-10

    I'm wondering why either the supposed "scripting function" is vaporware, or the supposed documentation is totally wrong or incomplete. After many hours of cutting and pasting the supposed "examples", I have discovered that no versions of even the simplest versions of those "scripts" produces anything other than an error message.

    If anyone thinks they have a <node> script that will function on a Win7 platform - even the simplest "Hello World" functionality - I'd love to see it.

     
  • Johny B
    Johny B
    2010-08-10

    To clarify, this supposed example script:

    <node TEXT="hello">
    <attribute NAME="script1" VALUE="=node.getNodeLevel() + " " + node.getText()"/>
    </node>

    produces (only) this error message - for which there is no reference or resolution available:

    Error while parsing file:freemind.main.XMLParseException: XML Parse Exception during parsing of a map element at line 4: Expected: =

     
  • Hello John,

    I suppose you have taken the quoted example from the following page:

    http://freemind.sourceforge.net/wiki/index.php/Scripting

    The page has contained an error in that example, an error that I have just fixed on that page. On the page, in the XML, there has to be the "&quot;" entity instead of plain quotation mark, or else the XML-attribute VALUE is wrongly closed with quotation marks. Note, however, that the example was one of how scripts are stored in XML, meant for FreeMind developers rather than for creators of scripts.

    To experiment with the scripting fuction, available only in FreeMind 0.9.0, I recommend you use the script editor. The script editor is available from the menu Tools > Script Editor. The Script Editor has the function Actions > Run available in its menu, a function that shows the results of the execution in the pane at the bottom, and it shows error messages there, if any.

    -Dan

     
  • Johny B
    Johny B
    2010-08-25

    Thank you Daniel, for correcting that error. Now, I can cut and paste that exact example and it actually works to add to a node text that I've already typed within that node.

    Unfortunately, I am unable to get ANYTHING else - any other snippet - especially any USEFUL snippet - to work…

    I have run the example scripts that build the object models. And, I have spent around 16 HOURS testing a wide variety of bits of those supposedly-existing objects - NONE OF WHICH APPEAR TO DO ANYTHING other than generating an error message.

    I wonder if many of these supposed capabilities are even real or implemented in this program?

    If they are real, I wonder why anyone would bother to build something that big and complicated - and then render it useless by omitting any meaningful documentation.

    What would be required, for instance, to explicitly copy a specific node (by ID, perhaps) onto a different node, in a distant portion of the map?

    Is that even a capability?

    Isn't copy and paste one of the most fundamental things?

    WHY would someone build that - and make it impossible for anyone to use?

     
  • John, I see that you are rather frustrated with scripting in FreeMind and I think that I can understand your frustration. Note, however, that I and the developers of the scripting capability in FreeMind are unpayed volunteers. Scripting in FreeMind 0.9.0 is real; the wiki page of Example scripts has been mostly contributed by FreeMind users.

    If you post the error message that you get when trying to run a script in the script editor (menu Tools > Script Editor, in there menu Actions > Run), and describe in detail the procedure that you have used to get that error message, then maybe I can help you further. -Dan

     
  • Johny B
    Johny B
    2010-08-26

    I asked a simple question:

    What would be required to copy a specific node (by ID, perhaps) onto a different node, in a distant portion of the map?

    Of course this also infers how one would refer to a specific node (by ID, perhaps) - when that information is not readily available within the UI?

    Your reply, instead of actually helping, was to invite me to "paste the error codes".

    Of course, because THERE IS NO MEANINGFUL DOCUMENTATION, my attempts are pretty random. And, if there's some imagining that taunting the user and baiting them and getting them to past near-random pathetic single commands that they can't make work - BECAUSE THERE'S NO MEANINGFUL DOCUMENTATION - is the most efficient and friendly way to help them use the tool that's so great - I'll play along with that strategy. Whatever it takes (hangs head appropriately bowing to L337 master of code).

    So, here's one of my guesses - and GUESS is what I mean, because, as I mentioned THERE'S NO MEANINGFUL DOCUMENTATION for how to use this convoluted crap:

    c.paste("ID_1100214201", "ID_1194615338")

    This is based on this entry from the object model that your own script generated - to wit:

    public void paste(MindMapNode,MindMapNode)

    Of course, there's NO DOCUMENTATION of how to reference a MindMapNode - whether that's by ID, or what else. So, I guessed at using the ID - and a half-dozen variations of ways of using it - like with quotes, without quotes, with the leading ID= and without, etc.

    And, of course, because you are the great and L337 developer of the software, you already know that this is pathetically wrong (feel free to insert the compulsory disparaging l337ist remarks in your reply) - and you already know that the error message evidence of my noobism will read:

    message: No signature of method: freemind.modes.mindmapmode.MindMapController.paste() is applicable for argument types: (java.lang.String, java.lang.String) values: {"ID_1100214201", "ID_1194615338"}Line number: -1

    And, of course, because you are the DEVELOPER, you have the secret decoder ring to know what this pile of characters actually means - and how to actually do the simple thing that I'm BEGGING NOW (appropriately as the noob user to the L337 master of digits) how, please, with sugar on top - to do the simple operation - IF IT IS EVEN POSSIBLE WITH THIS SCRIPTING MONSTROSITY.

    And, thank you.

     
  • Now you are being really rude. I have not developed scripting in Groovy in FreeMind. And I don't owe you anything. -Dan

     
  • Johny B
    Johny B
    2010-08-26

    I am in fact attempting humor - a rather dark flavor, but that's what goes along with being lied to (false documentation, by your own admission) - and being baited and jerked around - which is what I call asking me to post what I did and what error message I got - followed by just calling me rude and saying "you don't owe me" in response.

    You don't owe me anything. You were the one who *pretended* to know how this stuff supposedly works - said you fixed the error on the demo page - and BAITED me to send the command that won't work and the error message.

    I took the bait - and as expected, I got name-calling and "we don't owe you anything" - rather than meaningful assistance - or even proof that the CLAIMED functionality actually exists.

    Obviously, my references to L337 were appropriate: Jerk-around anyone who knows less than you, and when they get frustrated with non-functioning software or non-existent documentation or pissed off by being jerked around - blow them off and deny them any assistance. Blame them and call them "rude" because you were successful at baiting them with false claims, false examples - and jerking them around.

    You win. Again.

    Feel good yet?

    You *still* have the elite knowledge that would be helpful - if only there were someone WORTHY to receive it.

    Of course knowledge locked-away is precisely as useful as … no knowledge at all…

     
  • I admit that I have entered an error into the wiki when I was trying to document in the wiki a function that I have not developed myself and that I do not use myself: scripting. After your message here, I have fixed that error in the wiki. I have extended the documentation and tested the four examples that are found in http://freemind.sourceforge.net/wiki/index.php/Scripting

    When I am trying to help with software problems, I usually ask people to post steps to reproduce their problems, and post the results that the steps give for them including error messages. They are usually willing to do that, and what they post often leads to solutions to their problems. -Dan

     
  • Eric L.
    Eric L.
    2010-08-27

    Dear John,

    in your interesting statements, you forgot one simple point: you didn't pay anything for this software, and all the people working on this project don't get paid, if you are not happy with their work, feel free to improve it yourself, and if you can't do it, well "Don't look a gift horse in the mouth".

    And it looks like you didn't read the license that you accepted by using this program, please check point 11 of http://www.gnu.org/licenses/gpl-2.0.html

    BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

    3 last points:

    1. I strongly disagree with Dimitry, I don't want you as user on the Freeplane project.

    2. If your answer has the same tone, it will simply be ignored. Don't expect an answer from me.

    3. MindManager is a fine piece of software with the professional support you deserve, a license costs a mere 349$ on Mindjet's homepage.

    Sincerely yours, Eric

     
  • Johny B
    Johny B
    2010-08-27

    Dan, I understand the strategy you wanted to use. And, I understand the applicability when it's a complicated thing. I'm asking how to paste one specific node onto another. How to reference them and copy/paste. And, I'm UTTERLY CLUELESS about this scripting language - which to me, makes as much sense as a tangle of string.

    I literally sent you my best guess at a command to do this. I'm literally reading the xml and grabbing the ID# in an attempt to reference a specific node. Don't know what the hell else to do. Don't need to build a complicated thing - just the single thing I've asked about.

    Don't know why - if the capability is there, and it's not a long, complicated process to do what I'm asking - that someone didn't just post the one- or maybe three-liner to do it - or, to tell me that it's a complicated thing - in which case I'll literally abandon the idea because if it's that long every place I want it, then I'm not going to invest the time to do it.

    It's obvious, btw, ERIC, that it's more important to bash the noob and make them grovel, than it is to HELP SOMEONE. And, that, honestly does call into question, ERIC, some peoples' motivation behind building "free" software. Is it *really* altruism - or does it just provide an opportunity to be a know-it-all ASS to those who are so beneath?

    Thank you, Dimitry, for the link. I think there may be some information amongst those nicely-noob-level examples that may lead me in the right direction, once I have the time to tinker with it. I had really hoped to just get a straight answer so I could USE the thing rather than tinkering, but I suppose if you want to hot-rod the software, tinkering is sometimes part of the bargain - especially if nobody has before done what you would like to do…

    So, if any reader of this knows how to copy and past a specified node to a specific location via scripting (if that's actually possible - and actually simple to do), I'd appreciate the SIMPLEST demonstration of that - which a total noob idiot such as myself could actually make use of.

    Thanks. Over and out.