Module braille :: Class BrailleBuffer
[hide private]
[frames] | no frames]

Class BrailleBuffer

source code

                   object --+    
                            |    
baseObject.AutoPropertyObject --+
                                |
                               BrailleBuffer

Nested Classes [hide private]

Inherited from baseObject.AutoPropertyObject: __metaclass__

Instance Methods [hide private]
 
__init__(self, handler)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
clear(self)
Clear the entire buffer.
source code
 
_get_visibleRegions(self) source code
 
_get_regionsWithPositions(self) source code
 
bufferPosToRegionPos(self, bufferPos) source code
 
regionPosToBufferPos(self, region, pos, allowNearest=False) source code
 
bufferPosToWindowPos(self, bufferPos) source code
 
_get_windowEndPos(self) source code
 
_set_windowEndPos(self, endPos) source code
 
scrollForward(self) source code
 
scrollBack(self) source code
 
scrollTo(self, region, pos) source code
 
focus(self, region)
Bring the specified region into focus.
source code
 
update(self) source code
 
updateDisplay(self) source code
 
_get_cursorWindowPos(self) source code
 
_get_windowBrailleCells(self) source code
 
routeTo(self, windowPos) source code
 
saveWindow(self)
Save the current window so that it can be restored after the buffer is updated.
source code
 
restoreWindow(self)
Restore the window saved by saveWindow.
source code

Inherited from baseObject.AutoPropertyObject: invalidateCache

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Methods [hide private]

Inherited from baseObject.AutoPropertyObject: invalidateCaches

Class Variables [hide private]

Inherited from baseObject.AutoPropertyObject: cachePropertiesByDefault

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, handler)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

clear(self)

source code 

Clear the entire buffer. This removes all regions and resets the window position to 0.

focus(self, region)

source code 

Bring the specified region into focus. The region is placed at the start of the display. However, if the region has not set Region.focusToHardLeft and there is extra space at the end of the display, the display is scrolled left so that as much as possible is displayed.

Parameters:
  • region (Region) - The region to focus.

saveWindow(self)

source code 

Save the current window so that it can be restored after the buffer is updated. The window start position is saved as a position relative to a region. This allows it to be restored even after other regions are added, removed or updated. It can be restored with restoreWindow.

Postcondition: The window is saved and can be restored with restoreWindow.

restoreWindow(self)

source code 

Restore the window saved by saveWindow.

Precondition: saveWindow has been called.

Postcondition: If the saved position is valid, the window is restored. Otherwise, the nearest position is restored.