mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-11-19 12:38:18 +00:00
Dimension tool: a dimension locked while another is placed is no longer a level
The engine test that runs commands while a linear dimension is placed now also locks the other dimension, as well as hiding and deleting it, and checks that no guide runs along its level. docs/dimensions.md says that layers and groups count toward the 20,000 objects the tool reads for levels.
This commit is contained in:
@@ -2080,12 +2080,12 @@ fn a_dimension_of_the_same_points_lines_up_and_the_line_follows_the_pointer() {
|
||||
assert_eq!(recipe(&s, id).line_ends(), (pt(200.0, 186.0), pt(300.0, 186.0)));
|
||||
}
|
||||
|
||||
/// With Real-time Drawing off, a dimension hidden or deleted by a command while another is placed
|
||||
/// is no longer a level: no guide runs along its level.
|
||||
/// With Real-time Drawing off, a dimension hidden, locked or deleted by a command while another is
|
||||
/// placed is no longer a level: no guide runs along its level.
|
||||
#[test]
|
||||
fn a_dimension_hidden_or_deleted_while_another_is_placed_is_no_longer_a_level() {
|
||||
fn a_dimension_hidden_locked_or_deleted_while_another_is_placed_is_no_longer_a_level() {
|
||||
let plain = ViewInfo::default();
|
||||
for cmd in ["object.hide", "edit.clear"] {
|
||||
for cmd in ["object.hide", "object.lock", "edit.clear"] {
|
||||
let (mut s, first) = level_start(plain);
|
||||
run(&mut s, "prefs.set", json!({"key": "realTimeDrawing", "value": false}));
|
||||
linear_click(&mut s, plain, 200.0, 200.0);
|
||||
|
||||
+3
-2
@@ -73,8 +73,9 @@ The **Dimension Tool** is in the Modify section of the toolbar. Its strip offers
|
||||
With Smart Guides on, a linear dimension placed with its line within the Smart Guides snapping
|
||||
tolerance of the level of a parallel line of a linear dimension already drawn has its line on
|
||||
that level. The other dimension, and every layer and group it is in, must be visible and
|
||||
unlocked. The tool reads at most 20,000 visible, unlocked objects, from the frontmost back, so in
|
||||
a larger document a dimension past them is not a level. This is VectorCraft's own rule. With
|
||||
unlocked. The tool reads at most 20,000 visible, unlocked layers, groups and objects, from the
|
||||
frontmost back, so in a larger document a dimension past them is not a level. This is
|
||||
VectorCraft's own rule. With
|
||||
Alignment Guides on, a guide runs along the level across both lines while the dimension is
|
||||
placed.
|
||||
- **Angular:** hover a corner where two straight segments meet and drag outwards. Or click two
|
||||
|
||||
Reference in New Issue
Block a user