config(chunk): adjusted chunk rendering thresholds and recursion defaults
- Adjusted chunk rendering thresholds and preview line counts for improved display behavior. - Updated MIN_RECURSE_SAVINGS default from 5 to 4 to optimize recursion handling.
This commit is contained in:
@@ -16,7 +16,7 @@ env_uint! {
|
||||
// Configured max chunk lines.
|
||||
pub static MAX_CHUNK_LINES: usize = "PI_CHUNK_MAX_LINES" or 25 => [1, usize::MAX];
|
||||
// Configured min recurse savings.
|
||||
pub static MIN_RECURSE_SAVINGS: usize = "PI_CHUNK_MIN_SAVINGS" or 5 => [1, usize::MAX];
|
||||
pub static MIN_RECURSE_SAVINGS: usize = "PI_CHUNK_MIN_SAVINGS" or 4 => [1, usize::MAX];
|
||||
}
|
||||
|
||||
// ── Internal types ───────────────────────────────────────────────────────
|
||||
|
||||
@@ -9,11 +9,11 @@ type ChunkLookup<'a> = HashMap<&'a str, &'a ChunkNode>;
|
||||
|
||||
env_uint! {
|
||||
// Configured full display threshold.
|
||||
static FULL_DISPLAY_THRESHOLD: usize = "PI_CHUNK_FULL_DISPLAY_THRESHOLD" or 40 => [1, usize::MAX];
|
||||
static FULL_DISPLAY_THRESHOLD: usize = "PI_CHUNK_FULL_DISPLAY_THRESHOLD" or 80 => [1, usize::MAX];
|
||||
// Configured preview head lines.
|
||||
static PREVIEW_HEAD_LINES: usize = "PI_CHUNK_PREVIEW_HEAD_LINES" or 10 => [1, usize::MAX];
|
||||
static PREVIEW_HEAD_LINES: usize = "PI_CHUNK_PREVIEW_HEAD_LINES" or 12 => [1, usize::MAX];
|
||||
// Configured preview tail lines.
|
||||
static PREVIEW_TAIL_LINES: usize = "PI_CHUNK_PREVIEW_TAIL_LINES" or 5 => [1, usize::MAX];
|
||||
static PREVIEW_TAIL_LINES: usize = "PI_CHUNK_PREVIEW_TAIL_LINES" or 4 => [1, usize::MAX];
|
||||
}
|
||||
|
||||
pub fn line_to_containing_chunk_path(tree: &ChunkTree, line: u32) -> Option<String> {
|
||||
|
||||
Reference in New Issue
Block a user