[umbrello] [Bug 446020] Bird's eye view shows nothing at first open

Robert Hairgrove bugzilla_noreply at kde.org
Fri Nov 26 21:01:38 GMT 2021


https://bugs.kde.org/show_bug.cgi?id=446020

--- Comment #1 from Robert Hairgrove <code at roberthairgrove.com> ---
In the meantime, I was able to get the bird's eye view to show when a new
widget is added to the diagram. I noticed that selecting something in the tree
view would also trigger the view, so I looked at
UMLScene::slotObjectCreated(UMLObject* o). At the end of the method body, right
after the last line which calls "resizeSceneToItems()", I added these lines:

    UMLView* cv = activeView();
    if (cv) {
        // this should activate the bird view:
        UMLApp::app()->setCurrentView(cv, false);
    }

The last parameter to setCurrentView() has a default value of "true", which
causes the tree view focus to change e.g. from "class_A" (or whatever the new
widget was named) to the class diagram. Passing "false" keeps the focus on the
widget in the tree view, which seems much more intuitive to me since many
properties would normally need to be edited after creating and naming the
widget. In UMLApp::setCurrentView(), there is a call to "createBirdView()"
which deletes any existing BirdView object and creates a new one. Seems rather
heavy-handed to me, but I couldn't figure out which signals to catch that would
actually do anything useful.

However, there is much more "bugginess" about the bird's eye view (and the
drawing behavior in general) which needs to be looked at. For example, if I
have added two new classes to an empty class diagram and move one of them, the
other moves as well but in the opposite direction! There seems to be code
somewhere causing the scene to always be centered ... is this by design? I
would probably have to put widgets at the four corners of the virtual page to
keep things in the middle area from wandering about on the screen when one of
them is moved or resized. Takes a bit of getting used to.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the umbrello-devel mailing list