Devel FAQ

From OpenJUMP Wiki
Jump to navigation Jump to search

some developer questions

How to handle the BeanTools error message

What to do if the following warning comes up and jump does not start: JUMP: Warning: Extensions directory does not exist:

Solution: You need to copy the BeanTools folder from the distribution to your plugin folder location. Then OJ should start up sufficiently.

How to handle Log4j Warning

If you start OpenJump in your IDE the following error may appear:

log4j:WARN No appenders could be found for logger (com.vividsolutions.jump.I18N).
log4j:WARN Please initialize the log4j system properly. 

To solve the problem you need to find the file log4j.xml and set in VM arguments the path:

e.g.:

-Dlog4j.configuration=file:D:///develop/eclwork/openjumpetc/etc/log4j.xml 
    

Defining the Menu Order

When I keep adding new menu items by using PlugIns, it seems like the new menu items are displayed in the their loading sequence. Is there any way I can instruct JUMP to sort and display them in alphabetic order?

answer:

  • you are right - JUMP /OpenJUMP sorts the menu items by load order.
  • no - you can not order them by alphabet
  • but - you can define the position using the additional _pos:no_ sequence

example:

 context.getFeatureInstaller().addMainMenuItemWithJava14Fix(
      this,
      new String[] {MenuNames.VIEW},
      "Test Function"+"{pos:14}",
      false,
      null,
      null); 


Setting line colors for a layer

layer.getBasicStyle().setLineColor(Color.red);
layer.fireAppearanceChanged();