Ignore:
Timestamp:
01/23/13 14:49:09 (15 months ago)
Author:
Ales Erjavec <ales.erjavec@…>
Branch:
default
Message:

Fixed default output dock size when first shown/undocked.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Orange/OrangeCanvas/application/canvasmain.py

    r11264 r11270  
    273273        self.output_dock = QDockWidget(self.tr("Output"), 
    274274                                       objectName="output-dock") 
    275  
    276275        self.output_dock.setAllowedAreas(Qt.BottomDockWidgetArea) 
    277  
     276        output_view = OutputView() 
     277        # Set widget before calling addDockWidget, otherwise the dock 
     278        # does not resize properly on first undock 
     279        self.output_dock.setWidget(output_view) 
    278280        self.addDockWidget(Qt.BottomDockWidgetArea, self.output_dock) 
     281 
    279282        self.output_dock.setFloating(True) 
    280  
    281283        self.output_dock.hide() 
    282  
    283         output_view = OutputView() 
    284         self.output_dock.setWidget(output_view) 
    285284 
    286285        self.help_dock = QDockWidget(self.tr("Help"), 
    287286                                     objectName="help-dock") 
    288         self.addDockWidget(Qt.LeftDockWidgetArea, self.help_dock) 
    289         self.help_dock.setFloating(True) 
    290287        self.help_dock.setAllowedAreas(Qt.NoDockWidgetArea) 
    291  
    292         self.help_dock.hide() 
    293  
    294288        self.help_view = QWebView() 
    295289        self.help_dock.setWidget(self.help_view) 
     290        self.addDockWidget(Qt.LeftDockWidgetArea, self.help_dock) 
     291 
     292        self.help_dock.setFloating(True) 
     293        self.help_dock.hide() 
    296294 
    297295        self.setMinimumSize(600, 500) 
Note: See TracChangeset for help on using the changeset viewer.