Package peppy :: Package plugins :: Module buffer_list_mode :: Class BufferListMode
[frames] | no frames]

Class BufferListMode

              object --+                    
                       |                    
         wx._core.Object --+                
                           |                
         wx._core.EvtHandler --+            
                               |            
                 wx._core.Window --+        
                                   |        
                    wx._core.Control --+    
                                       |    
                   wx._controls.ListCtrl --+
                                           |
                              object --+   |
                                       |   |
 lib.column_autosize.ColumnAutoSizeMixin --+
                                           |
wx.lib.mixins.listctrl.ColumnSorterMixin --+
                                           |
                          object --+       |
                                   |       |
           lib.userparams.ClassPrefs --+   |
                                       |   |
                          object --+   |   |
                                   |   |   |
                    debug.debugmixin --+   |
                                       |   |
                         major.MajorMode --+
                                           |
                                          BufferListMode

View the list of currently opened buffers

Nested Classes
  stc_class
stc_class is used to associate this major mode with a storage mechanism (implementing the STCInterface).

Inherited from lib.userparams.ClassPrefs: __metaclass__

Instance Methods
EvtHandler
__init__(self, parent, wrapper, buffer, frame)
__init__(self, Window parent, int id=-1, Point pos=DefaultPosition, ...
 
GetListCtrl(self)
 
GetSortImages(self)
Returns a tuple of image list indexesthe indexes in the image list for an image to be put on the column header when sorting in descending order.
 
GetSecondarySortValues(self, col, key1, key2)
Returns a tuple of 2 values to use for secondary sort values when the items in the selected column match equal.
 
createListenersPostHook(self)
Hook to add custom listeners.
 
removeListenersPostHook(self)
Hook to remove custom listeners.
 
createColumns(self)
 
OnItemActivated(self, evt)
 
setSelectedIndexes(self, indexes)
Highlight the rows contained in the indexes array
 
getSelectedIndexes(self)
Return an array of indexes that are currently selected.
 
getFirstSelectedBuffer(self)
Get the Buffer object of the first selected item in the list.
 
moveSelected(self, dir)
Move the selection up or down.
 
getFlags(self, key)
Get the flags for the given key.
 
setFlag(self, flag)
Set the specified flag for all the selected items.
 
clearFlags(self)
Clear all flags for the selected items.
 
execute(self)
Operate on all the flags for each of the buffers.
 
reset(self, msg=None)
Reset the list.

Inherited from wx._controls.ListCtrl: Append, Arrange, AssignImageList, ClearAll, ClearColumnImage, Create, DeleteAllColumns, DeleteAllItems, DeleteColumn, DeleteItem, EditLabel, EnsureVisible, FindItem, FindItemAtPos, FindItemData, Focus, GetColumn, GetColumnCount, GetColumnWidth, GetCountPerPage, GetEditControl, GetFirstSelected, GetFocusedItem, GetImageList, GetItem, GetItemBackgroundColour, GetItemCount, GetItemData, GetItemFont, GetItemPosition, GetItemRect, GetItemSpacing, GetItemState, GetItemText, GetItemTextColour, GetMainWindow, GetNextItem, GetNextSelected, GetSelectedItemCount, GetTextColour, GetTopItem, GetViewRect, HitTest, HitTestSubItem, InReportView, InsertColumn, InsertColumnInfo, InsertColumnItem, InsertImageItem, InsertImageStringItem, InsertItem, InsertStringItem, IsSelected, IsVirtual, RefreshItem, RefreshItems, ScrollList, Select, SetColumn, SetColumnImage, SetColumnWidth, SetImageList, SetItem, SetItemBackgroundColour, SetItemColumnImage, SetItemCount, SetItemData, SetItemFont, SetItemImage, SetItemPosition, SetItemSpacing, SetItemState, SetItemText, SetItemTextColour, SetSingleStyle, SetStringItem, SetTextColour, SortItems, __repr__

Inherited from wx._core.Control: Command, GetAlignment, GetLabelText

Inherited from wx._core.Window: AcceptsFocus, AcceptsFocusFromKeyboard, AddChild, AdjustForLayoutDirection, AssociateHandle, CacheBestSize, CanSetTransparent, CaptureMouse, Center, CenterOnParent, Centre, CentreOnParent, ClearBackground, ClientToScreen, ClientToScreenXY, Close, ConvertDialogPointToPixels, ConvertDialogSizeToPixels, ConvertPixelPointToDialog, ConvertPixelSizeToDialog, DLG_PNT, DLG_SZE, Destroy, DestroyChildren, Disable, DissociateHandle, DragAcceptFiles, Enable, FindWindowById, FindWindowByName, Fit, FitInside, Freeze, GetAcceleratorTable, GetAdjustedBestSize, GetAutoLayout, GetBackgroundColour, GetBackgroundStyle, GetBestFittingSize, GetBestSize, GetBestSizeTuple, GetBestVirtualSize, GetBorder, GetCaret, GetCharHeight, GetCharWidth, GetChildren, GetClientAreaOrigin, GetClientRect, GetClientSize, GetClientSizeTuple, GetConstraints, GetContainingSizer, GetCursor, GetDefaultAttributes, GetDropTarget, GetEffectiveMinSize, GetEventHandler, GetExtraStyle, GetFont, GetForegroundColour, GetFullTextExtent, GetGrandParent, GetGtkWidget, GetHandle, GetHelpText, GetHelpTextAtPoint, GetId, GetLabel, GetLayoutDirection, GetMaxHeight, GetMaxSize, GetMaxWidth, GetMinHeight, GetMinSize, GetMinWidth, GetName, GetParent, GetPosition, GetPositionTuple, GetRect, GetScreenPosition, GetScreenPositionTuple, GetScreenRect, GetScrollPos, GetScrollRange, GetScrollThumb, GetSize, GetSizeTuple, GetSizer, GetTextExtent, GetThemeEnabled, GetToolTip, GetTopLevelParent, GetUpdateClientRect, GetUpdateRegion, GetValidator, GetVirtualSize, GetVirtualSizeTuple, GetWindowBorderSize, GetWindowStyle, GetWindowStyleFlag, GetWindowVariant, HasCapture, HasFlag, HasMultiplePages, HasScrollbar, HasTransparentBackground, Hide, HitTestXY, InheritAttributes, InheritsBackgroundColour, InitDialog, InvalidateBestSize, IsBeingDeleted, IsDoubleBuffered, IsEnabled, IsExposed, IsExposedPoint, IsExposedRect, IsFrozen, IsRetained, IsShown, IsShownOnScreen, IsTopLevel, Layout, LineDown, LineUp, Lower, MakeModal, Move, MoveAfterInTabOrder, MoveBeforeInTabOrder, MoveXY, Navigate, PageDown, PageUp, PopEventHandler, PopupMenu, PopupMenuXY, PostCreate, PrepareDC, PushEventHandler, Raise, Refresh, RefreshRect, RegisterHotKey, ReleaseMouse, RemoveChild, RemoveEventHandler, Reparent, ScreenToClient, ScreenToClientXY, ScrollLines, ScrollPages, ScrollWindow, SendSizeEvent, SetAcceleratorTable, SetAutoLayout, SetBackgroundColour, SetBackgroundStyle, SetBestFittingSize, SetCaret, SetClientRect, SetClientSize, SetClientSizeWH, SetConstraints, SetContainingSizer, SetCursor, SetDimensions, SetDoubleBuffered, SetDropTarget, SetEventHandler, SetExtraStyle, SetFocus, SetFocusFromKbd, SetFont, SetForegroundColour, SetHelpText, SetHelpTextForId, SetId, SetInitialSize, SetLabel, SetLayoutDirection, SetMaxSize, SetMinSize, SetName, SetOwnBackgroundColour, SetOwnFont, SetOwnForegroundColour, SetPosition, SetRect, SetScrollPos, SetScrollbar, SetSize, SetSizeHints, SetSizeHintsSz, SetSizeWH, SetSizer, SetSizerAndFit, SetThemeEnabled, SetToolTip, SetToolTipString, SetTransparent, SetValidator, SetVirtualSize, SetVirtualSizeHints, SetVirtualSizeHintsSz, SetVirtualSizeWH, SetWindowStyle, SetWindowStyleFlag, SetWindowVariant, ShouldInheritColours, Show, Thaw, ToggleWindowStyle, TransferDataFromWindow, TransferDataToWindow, UnregisterHotKey, Update, UpdateWindowUI, UseBgCol, Validate, WarpPointer

Inherited from wx._core.EvtHandler: AddPendingEvent, Bind, Connect, Disconnect, GetEvtHandlerEnabled, GetNextHandler, GetPreviousHandler, ProcessEvent, ProcessPendingEvents, SetEvtHandlerEnabled, SetNextHandler, SetPreviousHandler, Unbind

Inherited from wx._core.Object: GetClassName, IsSameAs

Inherited from lib.column_autosize.ColumnAutoSizeMixin: InsertSizedColumn, ResizeColumns

Inherited from wx.lib.mixins.listctrl.ColumnSorterMixin: GetColumnSorter, GetColumnWidths, OnSortOrderChanged, SetColumnCount, SortListItems

Inherited from major.MajorMode: OnContextMenu, OnUpdateUI, OnUpdateUIHook, __del__, applySettings, createEditWindow, createEventBindings, createEventBindingsPostHook, createListeners, createPostHook, createStatusBarInfo, createStatusIcons, createWindowPostHook, deleteWindow, deleteWindowPostHook, deleteWindowPre, deleteWindowPreHook, findMinorMode, focus, focusPostHook, getIcon, getPopupActions, getStatusBarWidths, getTabName, getTitle, getWelcomeMessage, idleHandler, idlePostHook, loadMinorModesPostHook, removeListeners, removeMinibuffer, resetStatusBar, save, savePostHook, savePreHook, setMinibuffer, setStatusText, settingsChanged, showBusy, showInitialPosition, showModified, tabActivatedHook, updateAui

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __str__

Class Methods
 
verifyProtocol(cls, url)
Hook to short-circuit the mode matching heuristics.

Inherited from major.MajorMode: verifyEditraType, verifyFilename, verifyMagic, verifyMetadata, verifyMimetype

Inherited from debug.debugmixin: dprint

Static Methods

Inherited from wx._controls.ListCtrl: GetClassDefaultAttributes

Inherited from wx._core.Window: FindFocus, GetCapture, NewControlId, NextControlId, PrevControlId

Class Variables
  keyword = 'BufferList'
The single-word keyword representing this major mode
  icon = 'icons/page_white_stack.png'
Pointer to the icon representing this major mode
  allow_threaded_loading = False
If this mode allows threading loading, set this True
  classprefs = <peppy.lib.userparams.PrefsProxy object at 0x8fdf...

Inherited from major.MajorMode: debuglevel, default_classprefs, emacs_synonyms, localkeymaps, mimetype, preferences_tab, regex, temporary

Inherited from lib.userparams.ClassPrefs: preferences_sort_weight

Properties

Inherited from wx._controls.ListCtrl: ColumnCount, CountPerPage, EditControl, FocusedItem, ItemCount, MainWindow, SelectedItemCount, TextColour, TopItem, ViewRect, thisown

Inherited from wx._core.Control: Alignment, LabelText

Inherited from wx._core.Window: AcceleratorTable, AutoLayout, BackgroundColour, BackgroundStyle, BestSize, BestVirtualSize, Border, Caret, CharHeight, CharWidth, Children, ClientAreaOrigin, ClientRect, ClientSize, Constraints, ContainingSizer, Cursor, DefaultAttributes, DropTarget, EffectiveMinSize, Enabled, EventHandler, ExtraStyle, Font, ForegroundColour, GrandParent, GtkWidget, Handle, HelpText, Id, Label, LayoutDirection, MaxHeight, MaxSize, MaxWidth, MinHeight, MinSize, MinWidth, Name, Parent, Position, Rect, ScreenPosition, ScreenRect, Shown, Size, Sizer, ThemeEnabled, ToolTip, TopLevel, TopLevelParent, UpdateClientRect, UpdateRegion, Validator, VirtualSize, WindowStyle, WindowStyleFlag, WindowVariant

Inherited from wx._core.EvtHandler: EvtHandlerEnabled, NextHandler, PreviousHandler

Inherited from wx._core.Object: ClassName

Inherited from object: __class__

Method Details

verifyProtocol(cls, url)
Class Method

 

Hook to short-circuit the mode matching heuristics.

For non-editing applications and client applications that connect to a server, this hook provides the ability to short-circuit the matching process and open a mode immediately.

This method must not attempt to open the url and read any data. All modes' verifyProtocol methods are called before the file is attempted to be opened, and attempting to read data here could mess up streaming files.

Parameters:
  • url - vfs.Reference object
Returns:
True to short circuit and use this mode.
Overrides: major.MajorMode.verifyProtocol
(inherited documentation)

__init__(self, parent, wrapper, buffer, frame)
(Constructor)

 

__init__(self, Window parent, int id=-1, Point pos=DefaultPosition, 
    Size size=DefaultSize, long style=LC_ICON, 
    Validator validator=DefaultValidator, String name=ListCtrlNameStr) -> ListCtrl

Returns: EvtHandler
Overrides: object.__init__
(inherited documentation)

GetSortImages(self)

 

Returns a tuple of image list indexesthe indexes in the image list for an image to be put on the column header when sorting in descending order.

Overrides: wx.lib.mixins.listctrl.ColumnSorterMixin.GetSortImages
(inherited documentation)

GetSecondarySortValues(self, col, key1, key2)

 

Returns a tuple of 2 values to use for secondary sort values when the items in the selected column match equal. The default just returns the item data values.

Overrides: wx.lib.mixins.listctrl.ColumnSorterMixin.GetSecondarySortValues
(inherited documentation)

createListenersPostHook(self)

 

Hook to add custom listeners.

Subclasses should override this method rather than createListeners to add their own listeners.

Overrides: major.MajorMode.createListenersPostHook
(inherited documentation)

removeListenersPostHook(self)

 

Hook to remove custom listeners.

Any listeners added by subclasses in createListenersPostHook should be removed here.

Overrides: major.MajorMode.removeListenersPostHook
(inherited documentation)

moveSelected(self, dir)

 

Move the selection up or down.

If dir < 0, move the selection to the item before the first currently selected item, and if dir > 0 move the selection to after the last item that is currently selected.

getFlags(self, key)

 

Get the flags for the given key.

If the key has not been seen before, create an initial state for those flags (which is all flags cleared) and return that.

setFlag(self, flag)

 

Set the specified flag for all the selected items.

flag: a single character representing the flag to set

execute(self)

 

Operate on all the flags for each of the buffers.

For each buffer item, process the flags to perform the requested action.

reset(self, msg=None)

 

Reset the list.

No optimization here, just rebuild the entire list.


Class Variable Details

classprefs

Value:
<peppy.lib.userparams.PrefsProxy object at 0x8fdf490>