Move to the start of the current line.
327356
def beginning_of_line(event):
    "  "
    buff = event.current_buffer
    buff.cursor_position += buff.document.get_start_of_line_position(after_whitespace=False)
264554
def move_up(self):
        """"""
        if self.current_item.parent is not None:
            self.current_item = self.current_item.parent

        for f in self._hooks["up"]:
            f(self)
        if self.current_item is self.root:
            for f in self._hooks["top"]:
                f(self)
        return self
806893
public void moveItem(int start, int end){
        M startItem = filteredItems.get(start);
        M endItem = filteredItems.get(end);

        int realStart = items.indexOf(startItem);
        int realEnd = items.indexOf(endItem);

        Collections.swap(items, realStart, realEnd);
        applyFilter();

        onItemMoved(startItem, realStart, realEnd);
        notifyItemMoved(realStart, realEnd);
    }
516741
def go_to_line(self, line):
        

        cursor = self.textCursor()
        cursor.setPosition(self.document().findBlockByNumber(line - 1).position())
        self.setTextCursor(cursor)
        return True
641033
def start(self):
        

        while not self.is_start(self.current_tag):
            self.next()
        self.new_entry()
432060
def start(self):
        """"""
        self.loop.create_task(self._read_line())
        self.loop.create_task(self._greeting())
1070136
def _start(self):
        """"""

        # TODO : make an update method instead

        last_call = 42
        while self._focus:
            sleep(1 / 100)

            mouse = pygame.mouse.get_pos()
            last_value = self.get()
            self.value_px = mouse[0]

            # we do not need to do anything when it the same value
            if self.get() == last_value:
                continue

            if last_call + self.interval / 1000 < time():
                last_call = time()
                self.func(self.get())
358608
private void moveSlotBefore() {
		/*
		 * int slot = 0; while (slot < currentPage.getNumRecords() &&
		 * searchRange.largerThan(getKey(currentPage, slot))) slot++;
		 * 
		 * currentSlot = slot - 1;
		 */
		// Optimization: Use binary search rather than sequential search
		int startSlot = 0, endSlot = currentPage.getNumRecords() - 1;
		int middleSlot = (startSlot + endSlot) / 2;
		SearchKey searchMin = searchRange.getMin();

		if (endSlot >= 0) {
			while (middleSlot != startSlot) {
				if (searchMin.compareTo(
						getKey(currentPage, middleSlot, keyType.length())) > 0)
					startSlot = middleSlot;
				else
					endSlot = middleSlot;

				middleSlot = (startSlot + endSlot) / 2;
			}
			
			if (searchMin.compareTo(
					getKey(currentPage, endSlot, keyType.length())) > 0)
				currentSlot = endSlot;
			else if (searchMin.compareTo(
					getKey(currentPage, startSlot, keyType.length())) > 0)
				currentSlot = startSlot;
			else
				currentSlot = startSlot - 1;
		} else
			currentSlot = -1;
	}
1233071
function isLineStart(loc) {
            const actualText = getActualLineIndentText(loc.line)
            return actualText.length === loc.column
        }
145975
def _startLineupsNode(self, name, attrs):
        """"""

        if name == 'lineup':
            self._lineupName = attrs.get('name')
            self._location = attrs.get('location')
            self._device = attrs.get('device')
            self._lineupType = attrs.get('type')
            self._postalCode = attrs.get('postalCode')
            self._lineupId = attrs.get('id')
            self._importer.new_lineup(self._lineupName, self._location,
                                     self._device, self._lineupType,
                                     self._postalCode, self._lineupId)

            self._progress.printMsg('Parsing lineup %s' % self._lineupName)
        elif name == 'map':
            self._stationId = attrs.get('station')
            self._channel = attrs.get('channel')
            self._channelMinor = attrs.get('channelMinor')
            self._validFrom = self._parseDateTime(attrs.get('from'))
            self._validTo = self._parseDateTime(attrs.get('to'))
            self._onAirFrom = None
            self._onAirTo = None
        elif name == 'onAir':
            self._onAirFrom = self._parseDateTime(attrs.get('from'))
            self._onAirTo = self._parseDateTime(attrs.get('to'))
1374846
private void switchToForward() {
        assert(state == State.ITER_CHECK_BWD ||
                (state == State.ITER_IN_FCD_SEGMENT && pos == limit) ||
                (state.compareTo(State.IN_NORM_ITER_AT_LIMIT) >= 0 && pos == normalized.length()));
        if(state == State.ITER_CHECK_BWD) {
            // Turn around from backward checking.
            start = pos = iter.getIndex();
            if(pos == limit) {
                state = State.ITER_CHECK_FWD;  // Check forward.
            } else {  // pos < limit
                state = State.ITER_IN_FCD_SEGMENT;  // Stay in FCD segment.
            }
        } else {
            // Reached the end of the FCD segment.
            if(state == State.ITER_IN_FCD_SEGMENT) {
                // The input text segment is FCD, extend it forward.
            } else {
                // The input text segment needed to be normalized.
                // Switch to checking forward from it.
                if(state == State.IN_NORM_ITER_AT_START) {
                    iter.moveIndex(limit - start);
                }
                start = limit;
            }
            state = State.ITER_CHECK_FWD;
        }
    }
605389
def get_start( line )
      retval = nil
      m = /^\s*;\s*start_part\s*(.+)[^\s]*/.match( line )
      if m && m[1]
        retval = m[1]
      end
      return retval
    end
1084797
def move_forward(self, seconds=None):
        """"""
        self._move(speed=SPEED_MAX, steering=0, seconds=seconds)
1250659
def do_move_to(self, element, decl, pseudo):
        """"""
        target = serialize(decl.value).strip()
        step = self.state[self.state['current_step']]
        elem = self.current_target().tree

        #  Find if the current node already has a move, and remove it.
        actions = step['actions']
        for pos, action in enumerate(reversed(actions)):
            if action[0] == 'move' and action[1] == elem:
                target_index = - pos - 1
                actions[target_index:] = actions[target_index+1:]
                break

        _, valstep = self.lookup('pending', target)
        if not valstep:
            step['pending'][target] = [('move', elem)]
        else:
            self.state[valstep]['pending'][target].append(('move', elem))
548006
private void firstInnerTableStart(Options opt) {
	w.print(linePrefix + linePrefix + "<tr>" + opt.shape.extraColumn() +
		"<td><table border=\"0\" cellspacing=\"0\" " +
		"cellpadding=\"1\">" + linePostfix);
    }
869243
function() {
        if (this.drawing) {
        this.ctx.beginPath();
        this.ctx.moveTo(this.lastPos.x, this.lastPos.y);
        this.ctx.lineTo(this.currentPos.x, this.currentPos.y);
        this.ctx.stroke();
        this.lastPos = this.currentPos;
      }
    }
344156
def move(self, place, distance = 1):
        """"""
        x, y = self._get_position()
        if place == 'up':
            y -= distance
        elif place == 'down':
            for i in range(distance): print
            nx, ny = self._get_position()
            y = ny
            self.move('beginning of line')
        elif place == 'left':
            x -= distance
        elif place == 'right':
            x += distance
        elif place == 'beginning of line':
            x = 0
        elif place == 'beginning of screen':
            x = 0
            y = self._get_console_info()['window']['top']
        else:
            raise ValueError("invalid place to move")
        self._set_position((x, y))