Results 1 to 1 of 1
  1. #1
    MUHU is offline Member
    Join Date
    Sep 2011
    Posts
    2
    Rep Power
    0

    Default Some Eclipse RCP questions

    Hi all,

    I have some questions regarding RCP topics, hopefully you can help me :)

    1. Ratio of views in a perspective.

    I haven't found anything useful yet in my internet search regarding the view ratios. How does they work? I know its from 0.05 to 0.95 but how do they connect together. I played a little bit with values but got nothing useful.

    I want something like this:

    *************************************************
    *********************** View 1 ********************
    *************************************************
    ---------------------------------------------------------------
    ********** **************************************
    ********** ****************View 4*****************
    ***View2*** **************************************
    ********** -------------------------------------------------
    ********** **************************************
    ********** ****************View 5*****************
    ********** **************************************
    ********** -------------------------------------------------
    ********** **************************************
    ------------ ****************View 6*****************
    ********** **************************************
    ********** -------------------------------------------------
    ***View3*** **************************************
    ********** ****************View 7*****************
    ********** **************************************

    View1 should be on top, view 2 and 3 below that on the left and the rest of the space should be equally distributed between view 4-7

    I was not able to get view 3 below view 2. and view 4-7 were not using the space equally...

    <perspectiveExtension
    targetID="perspective">
    <view
    closeable="false"
    id="View1"
    minimized="false"
    moveable="true"
    ratio="0.5"
    relationship="left"
    relative="org.eclipse.ui.editorss"
    showTitle="true"
    standalone="true"
    visible="true">
    </view>
    <view
    id="View2"
    ratio="0.1"
    relationship="bottom"
    relative="View1"
    visible="true">
    </view>
    <view
    id="View3"
    ratio="0.1"
    relationship="bottom"
    relative="View2"
    standalone="true"
    visible="true">
    </view>
    <view
    id="View4"
    minimized="false"
    ratio="0.25"
    relationship="right"
    relative="View2"
    visible="true">
    </view>
    <view
    id="View5"
    minimized="false"
    ratio="0.25"
    relationship="bottom"
    relative="View4"
    visible="true">
    </view>
    <view
    id="View6"
    minimized="false"
    ratio="0.25"
    relationship="bottom"
    relative="View5"
    visible="true">
    </view>
    <view
    id="View7"
    minimized="false"
    ratio="0.25"
    relationship="bottom"
    relative="View6"
    visible="true">
    </view>
    </perspectiveExtension>


    2. Command handler

    I have a treeview which contains a list of Node-Classes. The node class has a parent element which is null, when the node is a root element. I want the command handler just active when a child element is selected.

    Example:

    <handler
    class="de.agrar.fieldrecord.handlers.EditFieldHand ler"
    commandId="de.agrar.fieldrecord.views.edit.field">
    <activeWhen>
    <with
    variable="selection">
    <iterate
    ifEmpty="false"
    operator="or">
    <instanceof
    value="de.agrar.fieldrecord.views.field.FieldNode" >
    </instanceof>
    </iterate>
    </with>
    </activeWhen>
    </handler>

    I experimented with "and" and "with" statements but I could not get it work.

    3. How to deal with persistence?

    I want to use spring and hibernate for persisting my data, because I'm very familiar with this technology. But how do I abstract this?
    I created a plugin project "services", where I put in my logic, my entities and my DAOs. In the plugin activator I load my ApllicationContext and provide it for my logic classes. At least I try. When I start the application I get a NoClassDefFoundError. But I put in the libs as required to the target and the product definition. Do I missing something? Found it, I forgot to add the librarys to the manifest of the plugin.

    Or is this approach wrong?

    Thanks in advance for any information :)

    P.S.: Is there a code tag or something in this forum to format the source code? :)
    Last edited by MUHU; 09-23-2011 at 12:58 PM.

Similar Threads

  1. Replies: 2
    Last Post: 10-11-2013, 10:26 AM
  2. New Eclipse plugin: shared (and improved) Eclipse Templates
    By dougwightman in forum Java Software
    Replies: 0
    Last Post: 08-10-2011, 06:26 PM
  3. Replies: 0
    Last Post: 08-10-2011, 06:24 PM
  4. Questions from Teacher looking at Eclipse
    By Sparky9292 in forum Eclipse
    Replies: 2
    Last Post: 09-17-2009, 09:18 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •