Frame X test: the corner-to-corner lines from main's split canvas frames module

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
moppeeerandClaude Opus 5.5 committed 2026-10-29 15:28:38 +01:00
1 parent dccda2cd4c
commit cb036e06e2
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -30,7 +30,7 @@ mod view;
use column_guides::{COLUMN_DRAG, ColumnDrag, column_guide_at, spread_x_across};
use frames::{draw_frames, draw_selection};
#[cfg(test)]
use frames::{item_canvas_xf, overset_frames, overset_marks, ported_frames, text_frames_in};
use frames::{frame_x, item_canvas_xf, overset_frames, overset_marks, ported_frames, text_frames_in};
use guides::{GUIDE_DRAG, GUIDE_PRESS, GuideDrag, GuidePress, guide_readout, guide_spot, moving_guides, readout_at};
#[cfg(test)]
use guides::{guide_at, guide_drag_delta, guide_measure};
+1 -1
View File
@@ -135,7 +135,7 @@ fn draw_item_edges(painter: &egui::Painter, xf: &Xf, doc: &Document, it: &Item,
/// The X of an empty graphic frame, in its own space: a four-cornered frame joins its opposite
/// corners, so a frame slanted with Direct Selection keeps its X corner to corner, as InDesign
/// draws it; other shapes span their bounds.
fn frame_x(it: &Item) -> [(Point, Point); 2] {
pub(super) fn frame_x(it: &Item) -> [(Point, Point); 2] {
// A rectangle (slanted or not: four corner points, no handles). Ellipses, polygons (a
// four-sided one is a diamond) and curved paths keep the X across their bounds. Edited points
// make any of them a path: a four-cornered one whose corners would cross as a plus (a diamond,