Skip to content

layerling 1.125.0

Choose a tag to compare

@henmedia henmedia released this 30 Oct 21:11
· 1156 commits to main since this release
  • Screw drives and head diameter (Discussion #1052): A screw's drive was always a hex socket, sized from the thread diameter and 60 % of the head height deep, so a flat head on a large free diameter came out with an 11 mm socket barely a millimetre deep, and the head diameter could not be changed. Now the properties offer the drive - hex socket, Torx, Phillips or none - with its size (across flats, Torx outer diameter, span of the cross) and depth, up to nine tenths of the head, and the head diameter (across flats on a hex head). Left alone they follow the size as before, so saved screws do not change; a hex head still starts without a drive. The drive is cut into the exact body with true arcs for the Torx lobes, so the edge tool and the STEP export get it too, and the MCP bridge takes threadDrive, threadDriveSize, threadDriveDepth and threadHeadDiameter.

  • A port opening for USB, HDMI, DisplayPort and RJ45 sockets (Discussion #1049): A box for electronics needs an opening for the cable, and so far that meant a capsule or a box made a hole, sized from a data sheet and turned onto its side. The new shape Port opening, next to the teardrop, is that hole: seen from the front a rectangle with rounded corners, pushed through the wall along its own depth, a hole from the start. Its Socket list sets the opening from data sheets and standards: USB-C 9.4 x 3.7 mm with round ends (shell 8.94 x 3.26 plus 0.25 mm), USB-C with room for the plug 12.8 x 7 mm, Micro-USB 8 x 3.1 mm, USB-A 13 x 5.6 mm, HDMI 15.7 x 6.2 mm with both lower corners cut to a 10.8 mm base 1.2 mm high (Multicomp MC34931 recommended panel cut-out), Mini HDMI 11.2 x 3.1 mm (Würth WR-COM 685119136923 shell 10.5 x 2.5 plus 0.35 mm; the slant read from the drawing), DisplayPort 17.1 x 5.76 mm with the lower left corner cut 1.8 x 1.8 mm (VESA DisplayPort 1.2, figure 4-32), Mini DisplayPort 8.8 x 5.9 mm with both lower corners cut (VESA Mini DisplayPort 1.0 shell 8.30 wide; height and slant estimated), RJ45 16.7 x 14.4 mm (covers ERNI's 16.66 x 14.07 and a shielded jack's 16.38 x 14.38 minimum). A new field portProfile keeps the cut corners when the size is changed by hand; the list then shows Custom. An exact CAD body (lines and arcs laid along the depth, fully round ends as one half circle), so the edge tools and STEP take it; kernel tests check the face types. MCP: layerling_create_shape with kind port, portPreset picks the socket, cornerFillet and portProfile set the outline. Guide section in chapter 9, search words USB, HDMI, DisplayPort, RJ45, socket.

  • The sketch's rectangle, circle and ellipse start at your shape defaults (Discussion #1048): With the box set to 30 x 30 x 30 mm under Shape defaults, a box from the library came in at 30 mm, but the rectangle from the sketch's Shapes menu still came in at 20 x 20 mm, and the body made from it at 20 x 20 x 10. The sketch's shapes are outlines of their own and all started at a fixed 20 mm (SKETCH_PRIMITIVE_SIZE). Now the rectangle starts with the width and depth set for the box, and the circle and the ellipse with the width set for the cylinder as their diameter (sketchPrimitiveStartSize); without a default of one's own, and for the half circle, pie slice, bolt circle, triangle, hexagon, polygon and star, which have no counterpart in the library, they stay at 20 mm. The finished body still starts at 10 mm high. Chapter 7 of the guide says so in every language that describes the sketch's shapes. Unit tests in sketchPrimitives.test.ts. Reported by @makinglayerschannel in #1048.

  • Offset and Cut out work on every letter (Discussion #1037): Offsetting a text by 0.2 mm failed with "This body cannot be grown or shrunk by this distance" as soon as it held an A, B, M, N, W or 9 (in Multilanguage, Sans and Serif alike, with round or sharp edges); O, P, Q, R, 0 and 8 went through, so it was not the counters. The kernel's offset of the whole body trips over some of the letters' curves, and its offset of the outline alone fails on them too. When the kernel refuses a plain text (filled letters, no rounding), Offset now makes it a text with the "Wider" fill by the distance, or "Narrower" for a shrink, which moves the letters' own outlines with the smoothing the fill already has, and grows it by the distance at the top and the bottom about its middle (textOffsetAsFill); sharp edges give mitred corners. With "Keep the original" that text is the hole, and Cut out with a clearance takes the same way. The result stays an editable text rather than a fixed body. Guide (Edges and hollowing, English and German) says so. Unit tests in textFill.test.ts, kernel test in cadTextGrow.e2e.ts. Reported by @PabloJonesUK in #1037.

  • The object list sorts named shapes A to Z (Discussion #1046): The list showed the shapes only in the order they were made, so in a design with many renamed parts the names that belong together were scattered. A button with A–Z in the list's title bar now puts the shapes with a name of their own first, alphabetically with numbers counted as numbers ("Part 2" before "Part 10", Intl.Collator with numeric in the interface language), and leaves the ones that still carry the editor's name ("Box", "Group") below in the order they were added, the newest last, as the request asked. Parts inside groups are sorted the same way, and the search works as before on the sorted list. Only the list is sorted, never the design; the button stays lit while it sorts, and the choice is kept in the browser like the list's position. layerling_list_objects takes sort: "name" for the same order. sortObjectList in objectListSearch.ts, tests in objectListSearch.test.ts; chapter 4 of the guide says so in every language that describes the object list.

  • The Hirth joint stays round (Discussion #1016): The panel gave the Hirth joint a Length and a Width, and the side handles on the workplane stretched it into an oval, 30 by 54 mm in the report; its teeth then no longer interlock when one half is turned on the other. It now keeps one diameter like the cylinder and the star: the panel shows a single Diameter (it keeps the angle between the flanks as Length and Width did), every handle and the dimension mark change that one diameter, and canonicalizeShape sets the depth to the width, so a joint stretched before opens round again. The guide says so in English, German and Polish, the languages that describe the joint. Unit test in hirthGeometry.test.ts. Suggested by @Oldandretired in #1016.

  • store.php can keep the store outside the web root (Discussion #1050): A self-hosted copy behind PHP had its server store in a folder store next to store.php, inside the web root. store.php now reads LAYERLING_SHARED_PROJECTS_DIR, the same setting the Node route reads, and keeps the designs in that folder instead; without it the folder next to store.php stays the switch as before. Suggested by @foofoodog in Discussion #1050.

  • Polish brought up to date (#1044): The interface and the guide in Polish cover 1.124.1 again. Contributed by @cyryllo in #1044.

  • The buttons under the workspace settings keep their labels inside (#1045): On a Mac, "Meine Vorgabe verwenden" and "Als Vorgabe gesichert" wrapped onto two lines and ran out of the top and bottom of their buttons. The buttons had a fixed height of 34 px but nothing kept their label on one line, and next to the hint they were squeezed; Avenir Next is wider than Arial, so German labels no longer fitted. The labels now stay on one line and the buttons grow with them (min-height instead of height); the hint "Save the current settings for this design" wraps its own words instead, and when it would be narrower than 160 px the buttons move to a row of their own below it, right-aligned. Reported by @JK85659 in #1045.

  • The hinge with cones has an exact body (Discussion #1007): The cone hinge reached the CAD kernel only as its display mesh, so the edge tool only saw its triangles, Delete face refused it ("This body has no exact faces to delete") and the STEP export left it out. It is now made of parts the kernel knows, as the pin hinge is (hingeLocalParts): A's knuckles carry the cones, lying along the axis, each turned towards its point (hingeWorldParts), and each knuckle of B, with the strip under it, has its two recesses cut on its own before the cones in them are added - in the edge tool as a scope of its own, numbered so it never meets a group's (hingePartScope), in the STEP export knuckle by knuckle (buildHingeBody). Fingers, the flush leaf, screw holes and rounded corners come along. A hinge set as a hole inside a group goes to the edge tool as its mesh, so it is cut out whole; the pin hinge went as solid parts there before, and was not cut. As with any mesh in a group, Delete face then refuses the group, and for a hinge with many knuckles or screw holes the edge tool first asks about its triangles. The STEP export still leaves a hinge set as a hole out, as before. A chamfer or fillet laid on a cone hinge before keeps its body, but "Edit" may pick other edges, as their numbers changed. The guide (chapter 9, in every language that has it) and the MCP's description of hingeStyle say so. Unit tests in hingeGeometry.test.ts (the parts, the cones sunk into their knuckles, each tip where the display mesh has it, also turned, mirrored and folded, the scopes, both of the editor's calls and the hole), the edge tool's worker against the display mesh, alone and inside a group (cadConeHinge.e2e.ts), and the STEP round trip in stepRoundTrip.e2e.ts to a quarter of one recess. Contributed by @mlugo-apx.