Sketcher ConstrainDistanceX/it: Difference between revisions

From FreeCAD Documentation
(Updating to match new version of source page)
(Updating to match new version of source page)
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
<languages/>
<languages/>

<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
{{Docnav/it|[[Sketcher ConstrainLock/it|Blocca]]|[[Sketcher_ConstrainDistanceY/it|Distanza verticale]]|[[Sketcher_Workbench/it|Sketcher]]|IconL=Sketcher_ConstrainLock.svg‎|IconC=Workbench_Sketcher.svg|IconR=Constraint_VerticalDistance.svg}}
{{Docnav/it|[[Sketcher ConstrainLock/it|Blocca]]|[[Sketcher_ConstrainDistanceY/it|Distanza verticale]]|[[Sketcher_Workbench/it|Sketcher]]|IconL=Sketcher_ConstrainLock.svg‎|IconC=Workbench_Sketcher.svg|IconR=Constraint_VerticalDistance.svg}}
Line 14: Line 15:
</div>
</div>


<span id="Description"></span>
==Descrizione==
==Descrizione==


<div class="mw-translate-fuzzy">
Fissa una distanza orizzontale tra due punti. È applicabile tra tutti i punti dello schizzo. Quando viene selezionato un solo punto la distanza è riferita all'origine.
Fissa una distanza orizzontale tra due punti. È applicabile tra tutti i punti dello schizzo. Quando viene selezionato un solo punto la distanza è riferita all'origine.
</div>


[[File:Constraint_H_Distance.png]]
[[File:Constraint_H_Distance.png]]


<span id="Usage"></span>
==Utilizzo==
==Utilizzo==

See also: [[Sketcher_Workbench#Drawing_aids|Drawing aids]].

===[[Sketcher_Workbench#Continue_modes|Continue mode]]===


<div class="mw-translate-fuzzy">
<div class="mw-translate-fuzzy">
Line 31: Line 40:
</div>
</div>


===Run-once mode===
<div class="mw-translate-fuzzy">

'''Nota:''' lo strumento di vincolo può essere avviato anche senza selezione precedente, ma richiede la selezione di due punti o una linea. Per impostare la distanza dall'origine, è necessario selezionare anche il punto di origine dello schizzo. Di default il comando è in modalità continua per creare nuovi vincoli; per uscire dal comando premere il tasto destro del mouse o una volta il tasto {{KEY|ESC}}.
# Do one of the following:
</div>
#* Select one or two points.
#* Select a single line.
# Invoke the tool as explained above.
# Optionally [[Sketcher_Workbench#Edit_constraints|edit the constraint value]].
# A constraint is added.


== Scripting ==
== Scripting ==
Line 39: Line 53:
Distance from origin:
Distance from origin:


{{Code|code=Sketch.addConstraint(Sketcher.Constraint('DistanceX', Edge, PointOfEdge, App.Units.Quantity('123.0 mm')))}}
{{Code|code=Sketch.addConstraint(Sketcher.Constraint('DistanceX', Edge, PointOfEdge, -1, 1, App.Units.Quantity('123.0 mm')))}}


Distance between two vertices:
Distance between two vertices:
Line 45: Line 59:
{{Code|code=Sketch.addConstraint(Sketcher.Constraint('DistanceX', Edge1, PointOfEdge1, Edge2, PointOfEdge2, App.Units.Quantity('123.0 mm')))}}
{{Code|code=Sketch.addConstraint(Sketcher.Constraint('DistanceX', Edge1, PointOfEdge1, Edge2, PointOfEdge2, App.Units.Quantity('123.0 mm')))}}


Horizontal span of line (the GUI allows selecting the edge itself, but it is just a shorthand for using the two extremities of the same line:
Horizontal span of line (the GUI allows selecting the edge itself, but it is just a shorthand for using the two extremities of the same line):


{{Code|code=Sketch.addConstraint(Sketcher.Constraint('DistanceX', Line, 1, Line, 2, App.Units.Quantity('123.0 mm')))}}
{{Code|code=Sketch.addConstraint(Sketcher.Constraint('DistanceX', Line, 1, Line, 2, App.Units.Quantity('123.0 mm')))}}


The [[Sketcher_scripting|Sketcher scripting]] page explains the values which can be used for {{incode|Edge1}}, {{incode|Edge2}}, {{incode|Edge}}, {{incode| PointOfEdge1}}, {{incode| PointOfEdge2}}, {{incode|PointOfEdge}} and {{incode|Line}}, and contains further examples on how to create constraints from Python scripts.
The [[Sketcher_scripting|Sketcher scripting]] page explains the values which can be used for {{incode|Edge}}, {{incode|Edge1}}, {{incode|Edge2}}, {{incode|PointOfEdge}}, {{incode| PointOfEdge1}}, {{incode| PointOfEdge2}} and {{incode|Line}}, and contains further examples on how to create constraints from Python scripts.




Line 56: Line 70:
</div>
</div>


{{Sketcher Tools navi{{#translation:}}}}
{{Sketcher_Tools_navi{{#translation:}}}}
{{Userdocnavi{{#translation:}}}}
{{Userdocnavi{{#translation:}}}}
{{clear}}

Latest revision as of 15:08, 23 April 2024

Distanza orizzontale

Posizione nel menu
Sketch → Vincolo → Distanza orizzontale
Ambiente
Sketcher
Avvio veloce
Maiusc + H
Introdotto nella versione
-
Vedere anche
Distanza, Distanza verticale

Descrizione

Fissa una distanza orizzontale tra due punti. È applicabile tra tutti i punti dello schizzo. Quando viene selezionato un solo punto la distanza è riferita all'origine.

Utilizzo

See also: Drawing aids.

Continue mode

  1. Selezionare due punti o una linea
  2. Richiamare il comando in uno di questi modi:
    • Cliccare sull'icona Distanza orizzontale della barra degli strumenti.
    • Usare la scorciatoia da tastiera Maiusc + H.
    • Usare la voce Sketch → Vincoli → Distanza orizzontale dal menu principale.
  3. Si apre una finestra di dialogo per modificare o confermare il valore. Premere OK per confermare.

Run-once mode

  1. Do one of the following:
    • Select one or two points.
    • Select a single line.
  2. Invoke the tool as explained above.
  3. Optionally edit the constraint value.
  4. A constraint is added.

Scripting

Distance from origin:

Sketch.addConstraint(Sketcher.Constraint('DistanceX', Edge, PointOfEdge, -1, 1, App.Units.Quantity('123.0 mm')))

Distance between two vertices:

Sketch.addConstraint(Sketcher.Constraint('DistanceX', Edge1, PointOfEdge1, Edge2, PointOfEdge2, App.Units.Quantity('123.0 mm')))

Horizontal span of line (the GUI allows selecting the edge itself, but it is just a shorthand for using the two extremities of the same line):

Sketch.addConstraint(Sketcher.Constraint('DistanceX', Line, 1, Line, 2, App.Units.Quantity('123.0 mm')))

The Sketcher scripting page explains the values which can be used for Edge, Edge1, Edge2, PointOfEdge, PointOfEdge1, PointOfEdge2 and Line, and contains further examples on how to create constraints from Python scripts.