dymokomi/luced-3d
Source of release 0.11.9
0.11.9 / src / tool_curve_on_surface.luc
## Curve on Surface (Alias's): clicks on one face; the curve lies on it (its
## chart curve through the clicks, its 3D curve fitted to the surface).
## An Edit CAD step (edit_cad_curves.luc): with nothing selected the
## clicks place its points (placing_commands.luc).
from tool_record import Tool, ToolEntry, Pick
from parameter_rows import Parameter, whole
import pick_kinds
import edit_cad_curves
import cad_cook
pub func entry() -> ToolEntry:
return ToolEntry(edit_cad_curves.surface_verb, edit_cad_curves.surface_verb, "curve-on-surface", "Curves", [], [cad_cook.edit_kind], made)
func made() -> Tool:
let rows: list[Parameter] = [whole("Degree", 0, 5.0, 1.0, 11.0, "The curve's degree (lowered to what its points allow): 5 by default, Alias's 3 or 7 on request.")]
return entry().tool("Create", "Curves", "A curve lying on a face, through points clicked on it", [Pick("Points", [-1], kind = pick_kinds.components, slot = pick_kinds.nowhere)], rows, edit_cad_curves.cook,
numbers = [5.0], gesture = "place")