Navigates to the home position for the edit.
356934
def gotoHome(self):
        
        mode = QTextCursor.MoveAnchor
        
        # select the home
        if QApplication.instance().keyboardModifiers() == Qt.ShiftModifier:
            mode = QTextCursor.KeepAnchor
        
        cursor = self.textCursor()
        block  = projex.text.nativestring(cursor.block().text())
        
        cursor.movePosition( QTextCursor.StartOfBlock, mode )
        if block.startswith('>>> '):
            cursor.movePosition(QTextCursor.Right, mode, 4)
        elif block.startswith('... '):
            match = re.match('...\s*', block)
            cursor.movePosition(QTextCursor.Right, mode, match.end())
        
        self.setTextCursor(cursor)
176981
function handleDocumentMousemove(e) {
  let svg = overlay.parentNode.querySelector('svg.annotationLayer');
  let rect = svg.getBoundingClientRect();

  if (originX + (e.clientX - originX) < rect.right) {
    overlay.style.width = `${e.clientX - originX}px`;
  }

  if (originY + (e.clientY - originY) < rect.bottom) {
    overlay.style.height = `${e.clientY - originY}px`;
  }
}
24057
function left() {
        var parentRole = getParentRole();

        if (parentRole == "tablist") {
          moveFocus(-1, getFocusElements(focusedElement.parentNode));
        } else if (focusedControl.parent().submenu) {
          cancel();
        } else {
          moveFocus(-1);
        }
      }
496204
public function home()
    {
        $this->loadModel('Content.Contents');
        $contents = $this->Contents
            ->find('all')
            ->where([
                'Contents.promote' => 1,
                'Contents.status >' => 0,
                'Contents.language IN' => ['', null, I18n::locale()]
            ])
            ->order(['Contents.sticky' => 'DESC', 'Contents.created' => 'DESC'])
            ->limit((int)option('site_contents_home'));

        $this->set('contents', $contents);
        $this->viewMode('teaser');
    }
35514
def move_parent_up(self):
        
        cursor = self.nav.absolute_index
        if cursor > 0:
            level = max(self.content.get(cursor)['level'], 1)
            while self.content.get(cursor - 1)['level'] >= level:
                self._move_cursor(-1)
                cursor -= 1
            self._move_cursor(-1)
        else:
            self.term.flash()

        self.clear_input_queue()
128167
def _do_home_key(self, event=None, select=False):
        
        # get nb char to first significative char
        min_column = self.indenter_mode.min_column
        text = api.TextHelper(self).current_line_text()[min_column:]
        indent = len(text) - len(text.lstrip())
        delta = (self.textCursor().positionInBlock() - indent - min_column)
        cursor = self.textCursor()
        move = QtGui.QTextCursor.MoveAnchor
        if select:
            move = QtGui.QTextCursor.KeepAnchor
        if delta > 0:
            cursor.movePosition(QtGui.QTextCursor.Left, move, delta)
        else:
            cursor.movePosition(QtGui.QTextCursor.StartOfBlock, move)
            cursor.movePosition(QtGui.QTextCursor.Right, cursor.MoveAnchor, min_column)
        self.setTextCursor(cursor)
        if event:
            event.accept()
950475
function(){
      var place = this.autocomplete.getPlace();
      this.selected = true;

      if (!place.geometry){
        if (this.options.autoselect) {
          // Automatically selects the highlighted item or the first item from the
          // suggestions list.
          var autoSelection = this.selectFirstResult();
          this.find(autoSelection);
        }
      } else {
        // Use the input text if it already gives geometry.
        this.update(place);
      }
    }
918697
def step_next(self):
        """"""
        window_start = around(self.parent.value('window_start') +
                              self.parent.value('window_length') /
                              self.parent.value('window_step'), 2)

        self.parent.overview.update_position(window_start)
927737
def enter_position(self):
        ''''''
        state = self.state
        dlg = wx.TextEntryDialog(self, 'Enter new position', 'Position')
        dlg.SetValue("%f %f" % (state.lat, state.lon))
        if dlg.ShowModal() == wx.ID_OK:
            latlon = dlg.GetValue().split()
            dlg.Destroy()
            state.lat = float(latlon[0])
            state.lon = float(latlon[1])
            self.re_center(state.width/2,state.height/2, state.lat, state.lon)
            self.redraw_map()
771430
function Position(start) {
    this.start = start;
    this.end = { line: lineno, column: column };
    this.source = options.source;
  }
291607
function() {
					// Do not apply if nothing is found.
					if ( this._.cursors.length < 1 )
						return;

					// Remove the previous highlight if there's one.
					if ( this._.highlightRange )
						this.removeHighlight();

					// Apply the highlight.
					var range = this.toDomRange(),
						bookmark = range.createBookmark();
					highlightStyle.applyToRange( range, editor );
					range.moveToBookmark( bookmark );
					this._.highlightRange = range;

					// Scroll the editor to the highlighted area.
					var element = range.startContainer;
					if ( element.type != CKEDITOR.NODE_ELEMENT )
						element = element.getParent();
					element.scrollIntoView();

					// Update the character cursors.
					this.updateFromDomRange( range );
				}
372950
function() {
	    var _layout = this.options.layout;

		for (var i = 0; i < this._slides.length; i++) {
			this._slides[i].updateDisplay(this.options.width, this.options.height, _layout);
			this._slides[i].setPosition({left:(this.slide_spacing * i), top:0});
		};

		this.goToId(this.current_id, true, false);
	}
367996
function() {
    var center = this._shape.getLatLng();

    //this._moveMarker.setLatLng(center);
    this._resizeMarkers[0].setLatLng(this._getResizeMarkerPoint(center));

    // show resize marker
    this._shape._map.addLayer(this._markerGroup);
    this._updateMoveMarker();
    this._fireEdit();
  }
1297504
function _handleActiveEditorChange(event, current, previous) {
        if (current) { // Handle only full editors
            if (_mrofList.length === 0) {
                _initRecentFilesList();
            }

            var file = current.document.file;
            var paneId = current._paneId;
            _addToMROFList(file, paneId, current.getCursorPos(true, "first"));
        }

        if (previous) { // Capture the last know cursor position
            _updateCursorPosition(previous.document.file.fullPath, previous._paneId, previous.getCursorPos(true, "first"));
        }
    }
114611
private void adaptAreaPadding() {
        if (areas != null) {
            boolean paddingTopApplied = false;
            Area previousArea = null;
            View previousView = null;
            int scrollViewPaddingTop = 0;
            int scrollViewMarginBottom = 0;
            Iterator<Map.Entry<Area, View>> iterator = areas.entrySet().iterator();

            while (iterator.hasNext()) {
                Map.Entry<Area, View> entry = iterator.next();
                Area area = entry.getKey();
                View view = entry.getValue();

                applyDialogPaddingLeft(area, view);
                applyDialogPaddingRight(area, view);

                if (!paddingTopApplied) {
                    paddingTopApplied = applyDialogPaddingTop(area, view);
                }

                if (!iterator.hasNext()) {
                    applyDialogPaddingBottom(area, view);
                }

                if (previousArea != null) {
                    if (area == Area.BUTTON_BAR) {
                        applyDialogPaddingBottom(previousArea, previousView);
                    }

                    Pair<Integer, Integer> pair = addViewSpacing(previousArea, previousView, area);
                    scrollViewPaddingTop += pair.first != null ? pair.first : 0;
                    scrollViewMarginBottom += pair.second != null ? pair.second : 0;
                }

                previousArea = area;
                previousView = view;
            }

            if (scrollView != null) {
                LinearLayout.LayoutParams layoutParams =
                        (LayoutParams) scrollView.getLayoutParams();
                layoutParams.bottomMargin = scrollViewMarginBottom;
                scrollView.setPadding(scrollView.getPaddingLeft(),
                        scrollView.getPaddingTop() + scrollViewPaddingTop,
                        scrollView.getPaddingRight(), scrollView.getPaddingBottom());
            }
        }
    }
110726
function openLocation(location, noFlash) {
        var editor = EditorManager.getCurrentFullEditor();
        var codeMirror = editor._codeMirror;
        if (typeof location === "number") {
            location = codeMirror.posFromIndex(location);
        }
        codeMirror.setCursor(location);
        editor.focus();

        if (!noFlash) {
            codeMirror.addLineClass(location.line, "wrap", "flash");
            window.setTimeout(function () {
                codeMirror.removeLineClass(location.line, "wrap", "flash");
            }, 1000);
        }
    }
201707
def home(self):
        """"""
        self.command(c.LCD_RETURNHOME)
        self._cursor_pos = (0, 0)
        c.msleep(2)