Dmitrii,

I was hoping to get together a little video tutorial that shows how to
set-up Eclipse to create an OpenJUMP plug-in. But I haven't had time
to finish it.

What you need to do is configure the build path of your Eclipse
project for the plug-in. Go to the "Libraries" tab and hit the "add
external jars" button. Then browse to the two (2) OpenJUMP jars and
the JTS jar.

Let me know how that works, and I'll see if I can finish that tutorial video.

SS

2009/3/10 Zmitser Kozhukh <zmits...@mail.ru>:
> Hello!
> Yeah I am sorry too for not replying before - had to finish one paper past 
> weekend.
> But i've set up the project. The only thing is I somehow couldn't find jts 
> and jump class' libraries. Went to project preferences - user libraries - 
> import... but then couldn't find where those libraries are located.
> It would be great if you write where to find them, and I guess we can start 
> with coding :)
> Thank you.
> Cheers,
>        Dmitrii
>
> -----Original Message-----
> From: Sunburned Surveyor <sunburned.surve...@gmail.com>
> To: Zmitser Kozhukh <zmits...@mail.ru>
> Date: Mon, 2 Mar 2009 13:01:31 -0800
> Subject: Re: Re[4]: [jump-users] question about scripting in JUMP
>
>> Zmitser,
>>
>> Sorry I haven't gotten back to you for a couple of days. I had a busy 
>> weekend.
>>
>> Do you think you can handle setting up an Eclipse Java development
>> project for your plug-in? You'll need to create a new Java project and
>> add then JTS/JUMP libraries to your projects build path.
>>
>> If you have trouble with this process, I will throw together a quick
>> screencast that shows you how to do it. (This probably wouldn't be a
>> bad thing to have for future users.)
>>
>> I think there may be a better algorithm for your plug-in. If you are
>> trying to simplfy a linestring, you don't want to delete nodes
>> arbitrarily. Usually it is best to delete nodes that are very close to
>> other nodes, or nodes that are close to being on the same direction
>> (or "line-of-sight") as the previous and next nodes.
>>
>> This will allow you to eliminate the nodes that will change the
>> overall "shape" or form of the linestring the least significantly.
>>
>> We can discuss our method of simplification in more detail when we get
>> your Eclipse project set-up and start to write code.
>>
>> SS
>>
>> 2009/2/26 Zmitser Kozhukh <zmits...@mail.ru>:
>> > Hello!
>> >
>> > So I've downloaded Eclipse IDE for Java Developers and also JTS and JUMP 
>> > source codes.
>> >
>> > Well for instance if you want to measure some line (border, coastline etc. 
>> > ) and you take compass with certain radius. And with this compass move 
>> > along the line (similair like if you would have fixed step and measure 
>> > line by walking along it with this fixed step). In this way you can get 
>> > length of the line and also approximate its shape ( this i guess can be 
>> > usefull if you generalize some line for smaller scale map and want to get 
>> > rid of some "non-influencial" (tiny) parts of a line).
>> > I guess that for user there should be an option to choose radius of the 
>> > circle. Probably also to choose those LineStrings that he wants to 
>> > simplify.
>> > That is how I think about it right now.
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> >
>> > -----Original Message-----
>> > From: Sunburned Surveyor <sunburned.surve...@gmail.com>
>> > To: Zmitser Kozhukh <zmits...@mail.ru>
>> > Date: Wed, 25 Feb 2009 11:09:20 -0800
>> > Subject: Re: Re[2]: [jump-users] question about scripting in JUMP
>> >
>> >> Dmitrii,
>> >>
>> >> I'm glad to hear you would like to move forward with learning how to
>> >> write a plug-in. I'm going to copy our message to the developers
>> >> mailing list so that other subscribers might benefit. I think you'll
>> >> find writing a plug-in isn't much harder than "hello world". :] Some
>> >> programming skills will definitely help you in your pursuit of
>> >> cartography, and OpenJUMP may become your favorite mapping program. :]
>> >>
>> >> There are two things we need to do to get you started. Some of this
>> >> you may have already done. I'm at work right now, so I don't have a
>> >> lot of time to talk. But I will give you a few things now.
>> >>
>> >> The first thing you need to do is install the tools you will need to
>> >> write and compile that Java code for the plug-in. Most OpenJUMP
>> >> programmers use and IDE called Eclipse. (http://www.eclipse.org/) If
>> >> you don't have a strong objection, I would use this tool to write the
>> >> code for your plug-in. That will make it easier for us to work
>> >> together. You could also use the IDE from Sun called Netbeans.
>> >> (http://www.netbeans.org/) If you want something lightweight, you
>> >> could try something like JEdit (http://www.jedit.org/) or Notepad++.
>> >> (http://notepad-plus.sourceforge.net/uk/site.htm) You'll also need a
>> >> working installation of OpenJUMP and a Java Development Kit.
>> >>
>> >> It wouldn't hurt to download OpenJUMP's source code and bookmark the
>> >> Javadoc for OpenJUMP which is here:
>> >>
>> >> http://jump-pilot.sourceforge.net/javadoc/openjump_javadoc/
>> >>
>> >> It sounds like we'll be working with JTS geometry objects for your
>> >> plug-in, so you'll also want to download the source code for JTS. (JTS
>> >> is the geometry library that OpenJUMP uses.) You can find links to
>> >> this code and the Javadoc for JTS here:
>> >>
>> >> http://tsusiatsoftware.net/jts/main.html
>> >>
>> >> I use the Javadoc a lot when I am writing plug-ins.
>> >>
>> >> The second thing we need to do is understand a little better what you
>> >> want your plug-in to do. It sounds like you want to simplify
>> >> lineStrings based on a user entered radius. Is this correct?
>> >>
>> >> Will the user be selecting a single lineString for simplification, or
>> >> will they be processing all of features in a layer?
>> >>
>> >> Let me know when you get your development environment set up as
>> >> described above. Then answer the questions about what your plug-in
>> >> will do, and how the user will interact with it.
>> >>
>> >> Then we can start writing some code.
>> >>
>> >> The Sunburned Surveyor
>> >>
>> >> 2009/2/25 Zmitser Kozhukh <zmits...@mail.ru>:
>> >> > Hello!
>> >> > Thank you very much for your will to help me.
>> >> > Honestly I don't have big experience with programming. Like many of my 
>> >> > friends I was buying books about programming in Java, Python, C++ , but 
>> >> > I never went further than first couple of chapters ( like how to write 
>> >> > HelloWorld application, how to use certain functions, how to create 
>> >> > some simple procedures, how to use else if than operators). That is 
>> >> > because it was kinda meaningless (programming for the sake of 
>> >> > programming) for me that time. Now however, I started to study 
>> >> > cartography at university so the programming now can help to implement 
>> >> > some of my ideas ( so now it isnt like programming for the sake of 
>> >> > programming, but very help tool for implementing ideas :) ).
>> >> > So yeah I will be glad if you guide me through the process of writing 
>> >> > this plug-in and sure I will share it with everybody.
>> >> > So how do we start?
>> >> >
>> >> > best regards,
>> >> >               Dmitrii
>> >> >
>> >> > -----Original Message-----
>> >> > From: Sunburned Surveyor <sunburned.surve...@gmail.com>
>> >> > To: Zmitser Kozhukh <zmits...@mail.ru>, JUMP Users Discussion 
>> >> > <jump-us...@lists.jump-project.org>
>> >> > Date: Tue, 24 Feb 2009 07:07:42 -0800
>> >> > Subject: Re: [jump-users] question about scripting in JUMP
>> >> >
>> >> >> Dmitrii,
>> >> >>
>> >> >> I'm gald to hear that you are interested in learning more about
>> >> >> customizing OpenJUMP. There are two ways to do what you want. You can
>> >> >> write a beanshell script, or you can write a plug-in.
>> >> >>
>> >> >> Both require a limited knowledge of Java. Beanshell is probably the
>> >> >> easiest way to go, but learning to write a plug-in will give you more
>> >> >> opportunities to customize and extend OpenJUMP in the future.
>> >> >>
>> >> >> If you are willing to learn how to write a plug-in, then I can walk
>> >> >> you through the process myself. (You can also get plenty of help from
>> >> >> this mailing list.) I only ask that you share your code with others
>> >> >> when we are done. :]
>> >> >>
>> >> >> How much Java do you know? Do you have any programming experience?
>> >> >>
>> >> >> Let me know what you think. If you are ready to write a plug-in for
>> >> >> OpenJUMP, I'll post a message with what you need to get started.
>> >> >>
>> >> >> The Sunburned Surveyor
>> >> >>
>> >> >> P.S. - It sounds like you are trying to simplify (or remove nodes)
>> >> >> from a linear feature. There may already be existing code in OpenJUMP
>> >> >> that does this. Perhaps one of the other programmers will respond with
>> >> >> a message to let us know.
>> >> >>
>> >> >> On Tue, Feb 24, 2009 at 1:59 AM, Zmitser Kozhukh <zmits...@mail.ru> 
>> >> >> wrote:
>> >> >> > Hello!
>> >> >> > I have just started to use JUMP and aquaint myself with programming.
>> >> >> > So wanted to ask if someone can help me to write some simple script. 
>> >> >> > For example, I have some line with points. Than I want to select 
>> >> >> > starting point from this line, than to draw a circle with some fixed 
>> >> >> > radius centered at that point, than connect with straight line 
>> >> >> > initial point and point of intersection (between drawn circle and 
>> >> >> > the line). Than do the same thing , i.e. to draw circle around the 
>> >> >> > point of intersection, connect it with new intersection point and so 
>> >> >> > on...
>> >> >> > So anyone who knows how to script it please help. Or if someone 
>> >> >> > knows some helpfull resources about scripting in JUMP please let me 
>> >> >> > know.
>> >> >> > Thank you in advance!
>> >> >> > Dmitrii
>> >> >> > _______________________________________________
>> >> >> > jump-users mailing list
>> >> >> > jump-us...@lists.jump-project.org
>> >> >> > http://lists.refractions.net/mailman/listinfo/jump-users
>> >> >> >
>> >> >>
>> >> >
>> >> >
>> >>
>> >
>> >
>>
>
>

------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to