RfD: Support for layer specific resources
joey at infodrom.org
Thu Apr 15 20:20:50 CEST 2004
In the past, Thuban supported mostly local layers. As a result,
several dialogs were not classified layer-specific and hence
controlled through a general control within Thuban. This poses a
problem since the general control of Thuban which also creates menus
and legends thinks that all layers are "normal" layers.
As a result, if you try to open the properties dialog for a WMS layer,
Python will declare its love for you. It will do the very same if you
try to display the Table ("Show Table" on the context menu) for the
I guess that we should start to discuss how we could move
layer-specfic dialogs into the control of the dialog and add global
hooks where the layer can registrate features (dialog boxes and the
like) in the menu, legend (context menu), icon box, and main menu.
For this particular problem the source is in
Thuban/UI/legend.py for the Properties dialog
Thuban/UI/mainwindow.py for the Show Table dialog
If you read the backtrace Python prepares for you when you try to open
these dialogs, you'll see that this is buried deep in Thuban.
As a temporary local workaround in order to support the new
information and properties dialogs I have hooked them into the system
and modified the above mentioned files. However, in my oppinion this
is way too dirty and too much of a klugde to propose it as a general
solution. I may be willing to distribute the patches in private but
don't want to see them committed.
It's time to close the windows.
More information about the Thuban-devel