Special topic breakout: KWWidgets

From NAMIC Wiki
Jump to: navigation, search
Home < Special topic breakout: KWWidgets





KWWidgets Breakout Session

June 26th, 1-2pm

Location: Grier Rooms A & B: 34-401A & 34-401B







Attendees:

  • Yumin Yuan
  • Steve Pieper
  • Alex Yarmarkovich
  • Wendy Plesniak
  • Nicole Aucoin
  • Curt Lisle
  • Csaba Csoma
  • Brad Davis
  • David Gobbi
  • Kiran Shivanna
  • Kevin Teich
  • Jeff Hawley
  • Xiujuan Geng
  • James Harris
  • Gary Christensen
  • Paul Song
  • Alex. Gouaillard
  • Vincent Magnotta
  • Kiran Shivanna


Agenda

  • Roadmap (to help KWWidgets developers prioritize their work)
  • Widget feature requests / feedback
  • Talk about best approaches to making some widget behavior appear consistent across platforms.
  • Separate Tutorial Session for New Users (to happen possibly on Wednesday)

Specific Issues

From Nicole Aucoin

Directory selection dialog box on linux:

  • Bug: it pops up with a default width such that the right scroll bar isn't visible (see this screenshot; to reproduce it, start up Slicer3, go to the Models module, click on "Load Directory").
    Hint: the quickest workaround at this point would be to make the default width a tad larger so that the right scrollbar button shows up (Yumin).
  • Request: an entry box where I can type a path to reduce clicking through the tree (useful before setting up a favourite)
    Hint: Very doable (Yumin). Let's put all requests in the TODO list and prioritize.

From Curtis Lisle

idea #1 - I have had trouble initializing widgets to specific values in advance of user input. For example, I've created interfaces with sliders and buttons but I have had trouble getting the widgets to initialize in a state different then the default state. For example, setting a slider to value=26 in the middle of its range without dragging the mouse. The API looks like it is there, but I couldn't get it to work for me. I'm sure I tried setting the state before and after creation, if I remember, but no luck. It may be that I'm not updating the GUI successfully after changing values. Update: see screenshot; by state, I mean the widget-specific state, such as a check button is checked, or a slider is set at a particular value within its range. For example, the "Outline Display" button could be checked ON via API control of the program, not the user clicking on it. Before this picture was taken, I dragged the "element size" slider to 93% via the mouse. I'd like to instantiate the GUI, then set the actual positions and state values of the widgets. I just need clarity on the order of events to invoke through the API or help figuring out what I'm doing wrong. I notice that for KWWidgets, State usually means enabled/disabled to process user events. Instead, I am thinking about setting widget values from the program. I guess for CheckButtons, this would be Get/SetSelectedState(). For a vtkKWScale, this would be SetValue(). I tried setting these but didn't see the effect on the GUI. Maybe I am just not invoking Modified() correctly afterwards.


idea #2 - discuss when UI elements need to have Modified() / Update() invoked to refresh their appearance. I used a histogram widget on a project and had to experiment a lot calling the panel and RenderWidowWidget, etc. before I finally got the histogram to update when the input changed.

From Brad Davis

  • Bug: Double-clicking does not work with slicer3 and linux
  • Bug: File->Add Data does not use new file browser.
  • Request: Tree with additional columns widget
    Hint: The TkTreeCtrl library is in KWW and allows that, but one need to wrap it inside a C++ class, and this is a lot of work (Seb). Let's put all requests in the TODO list and prioritize.

From Alex:

  • I would lile to address the performance of building GUI in slicer3 Modules: When selecting a module for the first time (Volumes or Models) it takes noticable time before the UI panel is displayed.
  • Customizable tree widget similar to slicer2 model hierarchy editor: allow to add push-buttons or check boxes for the individual tree leaves.
    Hint: The TkTreeCtrl library is in KWW and allows that, but one need to wrap it inside a C++ class, and this is a lot of work (Seb). Let's put all requests in the TODO list and prioritize.

From Wendy:

Mostly pesky things:

  • Creating special versions of menubutton drop-down menus with scroll capability,
  • checkbuttons and radiobuttons with consistent "on/off" visual representation across platforms. (either special Slicer widgets or KWWidgets).

It would be good to decide on a strategy for addressing these things.

  • Also, if a radiobutton's indicator visibility is off, the widget gets rendered with a 3D effect (even if we're using an icon to display the button's on/off state). Can we turn that 3D effect off?

From KWW-Users mailing list

From Steve:

I'd like to have a discussion of GUI Tracing. In slicer3 we've started to experiment with a MRML-based tracing structure using the scene snapshot infrastructure, but we should consider if this is preferable to a GUI-based solution or not. See, for example, the vtkSlicerRecordSnapshotWidget.

Performance of the file browser could be improved (request for multi-threaded solution or a helper process that does the glob'ing so the main application does not block).

Look and feel issues:

  • On windows, the menu bar and scroll bar do not get the appearance
  • On linux, font size is sometimes way too small

Maybe just me, but I find the new file browser sometimes ignores doubleclicks -- perhaps it is more picky about any small mouse movement between clicks?

Configure event management is still a problem - dragging the split frame or hiding the left panel (with F5) causes a lot of extraneous ConfigureEvents.

From Gary and James:

I'd like to have a discussion of how to make a widget that reads one image plane at a time from a volume to make a multi-data set display. We have an implementation in wxWidgets that reads data from multiple files as a slider that changes the slice number without having to read the entire volumes into memory.

When displaying multiple vtkKWRenderWindows at once, the KWwidgets base class generates an error. Being able to display multiple renderwindows at one time is an essential requirement for our project.

The order of linking the ITK, VTK, TCL, TK and KWwidget libraries so that they do not conflict.

We want to access the KWwidgets' device client/handles for drawing on the controls.


From Vincent

There are issues with Slicer3 and fonts under Ubuntu Linux (Fiesty Fawn). The fonts are unreadable under this system. On the same system, Paraview fonts appear just fine. After performing some testing and evaluation, it appears that this is related to the order that fonts are resolved under Linux. We have a little script that will work around this by removing the X11 fonts on this sytem and only using the other system fonts for Slicer3. This is an ugly hack, but was close as we managed to get to track down the issue after approximately 3-4 hours of investigation.

#!/bin/bash

mv /usr/share/fonts/X11 /usr/share/fonts/X11-Slicer3
/opt/Slicer3/Slicer3
mv /usr/share/fonts/X11-Slicer3 /usr/share/fonts/X11