Paragraph style apply: the story's paragraph ranges, as main lists them

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
moppeeerandClaude Opus 5.5 committed 2026-10-29 22:10:49 +01:00
1 parent c43319e0a2
commit 776088c0d5
1 file changed
+1 -1
+1 -1
View File
@@ -328,7 +328,7 @@ fn apply_para_in_story(
f.chars.retain_differences(style_chars);
}
});
for (pi, range) in st.paras_touching(r.clone()).into_iter().filter(|(pi, _)| (first..=last).contains(pi)) {
for (pi, range) in st.para_ranges().into_iter().enumerate().filter(|(pi, _)| (first..=last).contains(pi)) {
let Some(pf) = st.paras.get(pi) else { continue };
let (_, base) = styles.resolve_para(pf);
let end = range.end.saturating_add(1).min(st.len());