.. link: .. description: .. tags: .. date: 2013/08/18 00:00:00 .. title: NINJA-IDE .. slug: minimap .. class:: alert alert-info pull-top .. contents:: *Module:* `minimap.py `_ API ============================================================================== No description. *Imports:* ------------ - `sys `_ - `PyQt4.QtGui.QBrush `_ - `PyQt4.QtGui.QColor `_ - `PyQt4.QtGui.QFontMetrics `_ - `PyQt4.QtGui.QFrame `_ - `PyQt4.QtGui.QGraphicsOpacityEffect `_ - `PyQt4.QtGui.QPainter `_ - `PyQt4.QtGui.QPen `_ - `PyQt4.QtGui.QPlainTextEdit `_ - `PyQt4.QtCore.QPropertyAnimation `_ - `PyQt4.QtGui.QTextOption `_ - `PyQt4.QtCore.Qt `_ - `PyQt4.QtCore.SIGNAL `_ - `ninja_ide.resources `_ - `ninja_ide.core.settings `_ *Global Attributes:* ---------------------- - `ACTIVATE_OPACITY [at ln:37] `_ ---- *Class:* `MiniMap(QPlainTextEdit) `_ ----------------------------------------------------------------------------------------------------------------------------- .. code:: python class MiniMap(QPlainTextEdit): No description. *Attributes* ~~~~~~~~~~~~~~ - `_parent [at ln:53] `_ - `highlighter [at ln:54] `_ - `lines_count [at ln:55] `_ - `slider [at ln:66] `_ *Function:* `__calculate_max() [at ln:69] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def __calculate_max(): No description. ---- *Function:* `__init__(parent) [at ln:42] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def __init__(parent): No description. ---- *Function:* `adjust_to_parent() [at ln:80] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def adjust_to_parent(): No description. ---- *Function:* `enterEvent(event) [at ln:103] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def enterEvent(event): No description. ---- *Function:* `leaveEvent(event) [at ln:110] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def leaveEvent(event): No description. ---- *Function:* `mousePressEvent(event) [at ln:117] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def mousePressEvent(event): No description. ---- *Function:* `resizeEvent(event) [at ln:122] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def resizeEvent(event): No description. ---- *Function:* `scroll_area(pos_parent, pos_slider) [at ln:126] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def scroll_area(pos_parent, pos_slider): No description. ---- *Function:* `set_code(source) [at ln:76] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def set_code(source): No description. ---- *Function:* `update_visible_area() [at ln:93] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def update_visible_area(): No description. ---- *Function:* `wheelEvent(event) [at ln:131] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def wheelEvent(event): No description. ---- *Class:* `SliderArea(QFrame) `_ ------------------------------------------------------------------------------------------------------------------------- .. code:: python class SliderArea(QFrame): No description. *Attributes* ~~~~~~~~~~~~~~ - `__scroll_margins [at ln:174] `_ - `_parent [at ln:140] `_ - `pressed [at ln:186] `_ *Function:* `__init__(parent) [at ln:138] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def __init__(parent): No description. ---- *Function:* `mouseMoveEvent(event) [at ln:189] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def mouseMoveEvent(event): No description. ---- *Function:* `mousePressEvent(event) [at ln:179] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def mousePressEvent(event): No description. ---- *Function:* `mouseReleaseEvent(event) [at ln:184] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def mouseReleaseEvent(event): No description. ---- *Function:* `move_slider(y) [at ln:176] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def move_slider(y): No description. ---- *Function:* `paintEvent(event) [at ln:156] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def paintEvent(event): | Paint over the widget to overlay its content. ---- *Function:* `update_position() [at ln:169] `_ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .. code:: python def update_position(): No description.