No announcement yet.
  • Filter
  • Time
Clear All
new posts

    A couple of questions related to splitpane resizebar

    Hi there. We're looking at perhaps improving our splitpane interface by adding a resize bar, but we're having some difficulty getting its UI to look the way we want.

    Basically, we have 2 thoughts.

    1. Our optimal solution would basically be a resizebar that looks like this (can't be dragged, just clicked on): We want a visible image, but we don't want the resizebar to be visible and take up horizontal width.
    Click image for larger version  Name:	Screenshot 2022-06-09 at 07.05.46.png Views:	0 Size:	25.6 KB ID:	268135
    However, the only way forward that i've found is setting setResizeBarClass("ImgSplitbar"), and then changing it in load_skin.
    What i haven't gotten to work:

    a) Changing the center align of the image. I've tried every thing i can think of, from setting parameters in the class in load_skin, to setting the stylename and applying various CSS parameters.
    The problem seems to be that there are a bunch of items inbetween the img and the object that has the style and parameters applied - the style gets applied to the outer resize bar div, but inside that there's a table with one row where the actual image is, so i can't really see how i can change the alignment.

    b) Making the image float "on top " of the actual resize bar as in the image above. The image is again, inside the div and i can't really see a way to change this.

    c) I would like to change the image when it is closing / opening, but it seems impossible. I tried adding a clickhandler like in the snippet below, but nothing changes.
    resizeBarConfig.addClickHandler(clickEvent -> {
                Splitbar newConfig = new Splitbar();
                mainSplitPane.setAutoChildProperties("resizeBar", newConfig);
                //redraw(); no difference
    If you have any pointers on the items above here i would love to hear them.


    2. As a not-as-good but acceptable alternative, set a button somewhere that does what the resize bar does when you click on it.

    However, i haven't managed to replicate what happens when i click on the resize bar. I've obviously tried all resize-methods i can find on the splitbar and navpane.
    Could you point me to what i should call in order to do the same thing the resize bar does when clicked on?

    I would love to get the resize bar to look as in the image, it looks pretty neat i think.
    Last edited by mathias; 9 Jun 2022, 01:21.