Home
last modified time | relevance | path

Searched refs:line (Results 1 – 13 of 13) sorted by relevance

/Held/src/utils/
H A Dbuffer.rs147 pub fn get_linesize(&self, line: u16) -> u16 { in get_linesize()
149 let line = buf.get(self.offset.load(Ordering::SeqCst) + line as usize); in get_linesize() localVariable
150 if line.is_none() { in get_linesize()
154 let line = line.unwrap(); in get_linesize() localVariable
156 line.data.len() as u16 in get_linesize()
159 pub fn get_linesize_abs(&self, line: u16) -> u16 { in get_linesize_abs()
161 let line = buf.get(line as usize); in get_linesize_abs() localVariable
162 if line.is_none() { in get_linesize_abs()
166 let line = line.unwrap(); in get_linesize_abs() localVariable
168 line.data.len() as u16 in get_linesize_abs()
[all …]
H A Dfile.rs78 for (idx, line) in data.iter().enumerate() { in store()
80 self.file.write(&line[..line.len()])?; in store()
82 self.file.write(&line)?; in store()
H A Dcursor.rs417 for (num, line) in content.iter().enumerate() { in update_line_prefix()
422 let flags = line.flags; in update_line_prefix()
436 for line in startline..max_line { in update_line_prefix()
437 self.move_to(Self::PREFIX_COL, (line - startline) as u16)?; in update_line_prefix()
438 let mut prefix = line.to_string(); in update_line_prefix()
/Held/src/config/
H A Dlastline_cmd.rs171 let line = usize::from_str_radix(s, 10); in flag() localVariable
172 if line.is_err() { in flag()
177 let line = line.unwrap(); in flag() localVariable
178 ui.buffer.add_line_flags(line - 1, LineState::FLAGED); in flag()
197 let line = usize::from_str_radix(arg, 10); in lock() localVariable
198 if line.is_err() { in lock()
203 let line = line.unwrap(); in lock() localVariable
204 ui.buffer.add_line_flags(line - 1, LineState::LOCKED); in lock()
225 let line = usize::from_str_radix(arg, 10); in unflag() localVariable
226 if line.is_err() { in unflag()
[all …]
H A Dappconfig.rs5 pub line: Option<DeserializeLineOption>, field
10 pub line: LineSetting, field
141 let line_setting = match self.line { in to_app_setting()
146 AppSetting { line: line_setting } in to_app_setting()
/Held/src/utils/ui/
H A Devent.rs63 let line = ui.buffer.get_line(y); in backspace() localVariable
64 if line.flags.contains(LineState::LOCKED) { in backspace()
72 let line = ui.buffer.get_line(y); in backspace() localVariable
76 String::from_utf8_lossy(&line.data[x as usize..]) in backspace()
H A Duicore.rs152 for line in content.iter() { in render_content()
153 let str = String::from_utf8_lossy(&line.data).to_string(); in render_content()
276 let mut cursor = CursorCrtl::new(buf.clone(), setting.line); in new()
/Held/
H A Dconfig.yaml1 line:
H A DREADME.md53 - ``line`` 整体行设置
H A DLICENSE632 the "copyright" line and a pointer to where the full notice is found.
634 <one line to give the program's name and a brief idea of what it does.>
/Held/src/utils/ui/mode/
H A Dcommon.rs69 fn move_to_line(&self, ui: &mut MutexGuard<UiCore>, line: u16) -> io::Result<()> { in move_to_line()
72 let new_y = ui.buffer.goto_line(line as usize); in move_to_line()
H A Dmode.rs199 let line = ui.buffer.get_line(ui.cursor.y()).data; in jump_to_first_char() localVariable
201 for char in line { in jump_to_first_char()
597 let line = ui.buffer.get_line(line_idx); in enter() localVariable
598 if line.flags.contains(LineState::LOCKED) { in enter()
665 let line = ui.buffer.get_line(y); in input_data() localVariable
666 if line.flags.contains(LineState::LOCKED) { in input_data()
H A Dnormal.rs588 let line = in exec_f_cmd() localVariable
590 let pos = line.find(to_find); in exec_f_cmd()
614 let line = in exec_F_cmd() localVariable
616 let pos = line.rfind(to_find); in exec_F_cmd()