Changeset 2947

Show
Ignore:
Timestamp:
03/21/07 04:49:49 (2 years ago)
Author:
ed
Message:

Removed all the stuff that was deprecated in 0.7 in anticipation of the 0.8 release. These are:

- The dRadioGroup class. This has been replaced by dRadioList
- The use of the 'borderFlags' parameter in sizers
- The dGridSizer methods 'isRowGrowable()' and 'isColGrowable()', which have been replaced by 'getRowExpand()' and 'getColExpand()', respectively.

Any remaining references to these items have been updated in code that contained them.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/dabo/dEvents.py

    r2923 r2947  
    274274        return issubclass(objectClass, (ui.dBitmapButton, ui.dButton, 
    275275                ui.dCheckBox, ui.dComboBox, ui.dDropdownList, ui.dEditBox, 
    276                 ui.dListBox, ui.dRadioGroup, ui.dSlider, ui.dSpinner, ui.dTextBox, 
     276                ui.dListBox, ui.dRadioList, ui.dSlider, ui.dSpinner, ui.dTextBox, 
    277277                ui.dTimer, ui.dToggleButton, ui.dMenuItem)) 
    278278    appliesToClass = classmethod(appliesToClass) 
  • trunk/dabo/ui/uiwx/__init__.py

    r2931 r2947  
    112112from dMenuItem import * 
    113113import dMessageBox 
    114 from dRadioGroup import dRadioGroup 
    115114from dRadioList import dRadioList 
    116115from dPanel import dPanel 
     
    10831082 
    10841083def fontMetricFromFont(txt, font): 
     1084    if isinstance(font, dabo.ui.dFont): 
     1085        font = font._nativeFont 
    10851086    wind = wx.Frame(None) 
    10861087    dc = wx.ClientDC(wind) 
  • trunk/dabo/ui/uiwx/dGridSizer.py

    r2945 r2947  
    6363    def append(self, item, layout="normal", row=-1, col=-1,  
    6464            rowSpan=1, colSpan=1, alignment=None, halign="left",  
    65             valign="middle", border=0, borderSides=("all",),  
    66             borderFlags=("all",), flag=None): 
     65            valign="middle", border=0, borderSides=("all",), flag=None): 
    6766        """ Inserts the passed item at the specified position in the grid. If no 
    6867        position is specified, the item is inserted at the first available open  
    6968        cell as specified by the Max* properties.        
    7069        """ 
    71         if borderSides is None: 
    72             if borderFlags is not None: 
    73                 warnings.warn(_("Deprecation warning: use 'borderSides' parameter instead."), DeprecationWarning, stacklevel=2) 
    74                 borderSides = borderFlags 
    7570        (targetRow, targetCol) = self._determineAvailableCell(row, col) 
    7671        if isinstance(item, (tuple, int)): 
     
    245240         
    246241     
    247     def isRowGrowable(self, row): 
    248         warnings.warn(_("Deprecated; use 'getRowExpand' instead."), DeprecationWarning, stacklevel=2) 
    249         return self.getRowExpand(row) 
    250      
    251      
    252242    def getRowExpand(self, row): 
    253243        """Returns True if the specified row is growable.""" 
     
    255245         
    256246         
    257     def isColGrowable(self, col): 
    258         warnings.warn(_("Deprecated; use 'getColExpand' instead."), DeprecationWarning, stacklevel=2) 
    259         return self.getColExpand(col) 
    260  
    261  
    262247    def getColExpand(self, col): 
    263248        """Returns True if the specified column is growable.""" 
  • trunk/dabo/ui/uiwx/dSizerMixin.py

    r2926 r2947  
    8181             
    8282    def append(self, obj, layout="normal", proportion=0, alignment=None, 
    83             halign="left", valign="top", border=None, borderSides=None, 
    84             borderFlags=None): 
     83            halign="left", valign="top", border=None, borderSides=None): 
    8584        """Adds the passed object to the end of the sizer layout.""" 
    86  
    87         if borderSides is None: 
    88             if borderFlags is not None: 
    89                 dabo.errorLog.write(_("Depracation warning: use 'borderSides' parameter instead.")) 
    90                 borderSides = borderFlags 
    9185        return self.insert(len(self.Children), obj, layout=layout, proportion=proportion,  
    9286                alignment=alignment, halign=halign, valign=valign, border=border,  
     
    10296 
    10397    def insert(self, index, obj, layout="normal", proportion=0, alignment=None, 
    104             halign="left", valign="top", border=None, borderSides=None,  
    105             borderFlags=None): 
     98            halign="left", valign="top", border=None, borderSides=None): 
    10699        """Inserts the passed object into the sizer layout at the specified position.""" 
    107         if borderSides is None: 
    108             if borderFlags is not None: 
    109                 dabo.errorLog.write(_("Deprecation warning: use 'borderSides' parameter instead.")) 
    110                 borderSides = borderFlags 
    111100        if isinstance(layout, int): 
    112101            # proportion was passed first 
     
    154143     
    155144    def prepend(self, obj, layout="normal", proportion=0, alignment=None, 
    156             halign="left", valign="top", border=None, borderSides=None,  
    157             borderFlags=None): 
     145            halign="left", valign="top", border=None, borderSides=None): 
    158146        """Insert the object at the beginning of the sizer layout.""" 
    159147        return self.insert(0, obj, layout=layout, proportion=proportion, 
    160148                alignment=alignment, halign=halign, valign=valign, border=border, 
    161                 borderSides=None, borderFlags=None)             
     149                borderSides=None) 
    162150    prepend.__doc__ += _doc_additions 
    163151     
     
    626614        if layout.lower() in ("expand", "ex", "exp", "x", "grow"): 
    627615            _wxFlags = _wxFlags | self.expandFlag 
     616        elif layout.lower() == "shaped": 
     617            _wxFlags = _wxFlags | wx.SHAPED 
    628618        elif layout.lower() == "fixed": 
    629619            _wxFlags = _wxFlags | self.fixedFlag