Bauteil: Ansichtsschraffur neben Schnittschraffur
Bauteil trägt jetzt zwei Schraffuren: die bestehende hatchId als Schnittschraffur (nur wo tatsächlich aufgeschnitten) und ein neues optionales Feld viewHatchId als Ansichtsschraffur für die frontale, ungeschnittene Sicht. Die Deckenpoché im Grundriss — die Decke liegt über der horizontalen Schnittebene, wird also frontal gesehen — nutzt nun die Ansichtsschraffur (Default weiss/leer) statt pauschal keiner. Schnitt-Pfade und die echt geschnittene Wand-Grundriss-Poché bleiben auf der Schnittschraffur. Editierbar im Ressourcen-Manager.
This commit is contained in:
+14
-1
@@ -319,8 +319,17 @@ export const de = {
|
||||
"objinfo.room.editStamp": "Stempel bearbeiten …",
|
||||
"objinfo.wall.floorAboveNone": "Kein oberes Geschoss",
|
||||
"levels.addFloor": "+ Geschoss",
|
||||
"levels.addSection": "+ Schnitt",
|
||||
"levels.addElevation": "+ Ansicht",
|
||||
"levels.addDrawing": "+ Zeichnung",
|
||||
"layers.addCategory": "+ Ebene",
|
||||
|
||||
// ── Zeichnungsebenen: Kategorie-Titel (einklappbare Gruppen) ─────────────
|
||||
"levelCat.floor": "Geschosse",
|
||||
"levelCat.section": "Schnitte",
|
||||
"levelCat.elevation": "Ansichten",
|
||||
"levelCat.drawing": "2D-Zeichnungen",
|
||||
"levelCat.collapse": "Kategorie ein-/ausklappen",
|
||||
"nav.visibility": "Sichtbarkeit",
|
||||
"nav.hide": "Ausblenden",
|
||||
"nav.show": "Einblenden",
|
||||
@@ -417,6 +426,8 @@ export const de = {
|
||||
|
||||
// ── Default-Namen neuer Elemente ─────────────────────────────────────────
|
||||
"default.floorName": "Geschoss {n}",
|
||||
"default.sectionName": "Schnitt {n}",
|
||||
"default.elevationName": "Ansicht {n}",
|
||||
"default.drawingName": "Zeichnung {n}",
|
||||
"default.categoryName": "Neue Ebene",
|
||||
"default.subCategoryName": "Neue Sub-Ebene",
|
||||
@@ -475,7 +486,9 @@ export const de = {
|
||||
"resources.components.placeholder": "Bauteil",
|
||||
"resources.col.name": "Name",
|
||||
"resources.col.color": "Farbe",
|
||||
"resources.col.hatch": "Schraffur",
|
||||
"resources.col.hatch": "Schnittschraffur",
|
||||
"resources.col.viewHatch": "Ansichtsschraffur",
|
||||
"resources.viewHatch.none": "(keine)",
|
||||
"resources.col.prio": "Prio",
|
||||
"resources.col.prio.hint": "Höhere Priorität läuft am Stoß durch",
|
||||
"resources.col.texture": "Textur",
|
||||
|
||||
+14
-1
@@ -317,8 +317,17 @@ export const en: Record<TranslationKey, string> = {
|
||||
"objinfo.room.refFloor": "Reference floor",
|
||||
"objinfo.room.editStamp": "Edit stamp …",
|
||||
"levels.addFloor": "+ Floor",
|
||||
"levels.addSection": "+ Section",
|
||||
"levels.addElevation": "+ Elevation",
|
||||
"levels.addDrawing": "+ Drawing",
|
||||
"layers.addCategory": "+ Layer",
|
||||
|
||||
// Drawing levels: category titles (collapsible groups).
|
||||
"levelCat.floor": "Floors",
|
||||
"levelCat.section": "Sections",
|
||||
"levelCat.elevation": "Elevations",
|
||||
"levelCat.drawing": "2D drawings",
|
||||
"levelCat.collapse": "Collapse/expand category",
|
||||
"nav.visibility": "Visibility",
|
||||
"nav.hide": "Hide",
|
||||
"nav.show": "Show",
|
||||
@@ -414,6 +423,8 @@ export const en: Record<TranslationKey, string> = {
|
||||
|
||||
// Default names.
|
||||
"default.floorName": "Floor {n}",
|
||||
"default.sectionName": "Section {n}",
|
||||
"default.elevationName": "Elevation {n}",
|
||||
"default.drawingName": "Drawing {n}",
|
||||
"default.categoryName": "New layer",
|
||||
"default.subCategoryName": "New sub-layer",
|
||||
@@ -471,7 +482,9 @@ export const en: Record<TranslationKey, string> = {
|
||||
"resources.components.placeholder": "Component",
|
||||
"resources.col.name": "Name",
|
||||
"resources.col.color": "Color",
|
||||
"resources.col.hatch": "Hatch",
|
||||
"resources.col.hatch": "Section hatch",
|
||||
"resources.col.viewHatch": "View hatch",
|
||||
"resources.viewHatch.none": "(none)",
|
||||
"resources.col.prio": "Prio",
|
||||
"resources.col.prio.hint": "Higher priority runs through at the join",
|
||||
"resources.col.texture": "Texture",
|
||||
|
||||
+8
-1
@@ -108,8 +108,15 @@ export interface Component {
|
||||
name: string;
|
||||
/** Füllfarbe im Grundriss (Poché) und 3D-Diffusfarbe. */
|
||||
color: string;
|
||||
/** Schnitt-Schraffur → Hatch Manager. */
|
||||
/** Schnitt-Schraffur → Hatch Manager. Gilt, wo das Bauteil echt geschnitten ist. */
|
||||
hatchId: string;
|
||||
/**
|
||||
* Ansichts-Schraffur → Hatch Manager. Gilt, wo das Bauteil frontal/ungeschnitten
|
||||
* gesehen wird (z. B. Deckenpoché im Grundriss: die Decke liegt über der
|
||||
* horizontalen Schnittebene und wird von unten gesehen, nicht aufgeschnitten).
|
||||
* Leer/`undefined` ⇒ keine Schraffur (weiss).
|
||||
*/
|
||||
viewHatchId?: string;
|
||||
/** Optionale 3D-Textur (vorerst ignoriert). */
|
||||
texture3d?: string;
|
||||
/**
|
||||
|
||||
@@ -1200,8 +1200,9 @@ function addReferenceLine(out: Primitive[], wall: Wall, greyed: boolean): void {
|
||||
* Schichtaufbau einer Decke in Z (oben → unten) — von oben unsichtbar. Die
|
||||
* Schichtbänderung erscheint daher NUR im Schnitt (siehe `toSection.ts`), nicht
|
||||
* hier. Im Detailgrad „grob" entfällt die Schraffur (nur Fläche + Umriss);
|
||||
* „mittel"/„fein" zeigen die Component-Schraffur. `lwMm` ist die Kategorie-
|
||||
* Strichstärke.
|
||||
* „mittel"/„fein" zeigen die Ansichts-Schraffur des Bauteils (`viewHatchId`,
|
||||
* Default weiss) — die frontal gesehene Aufsicht ist kein Schnitt. `lwMm` ist
|
||||
* die Kategorie-Strichstärke.
|
||||
*/
|
||||
function addCeilingPoche(
|
||||
out: Primitive[],
|
||||
@@ -1219,11 +1220,16 @@ function addCeilingPoche(
|
||||
const outlineMm = lwMm * OUTLINE_DETAIL_FACTOR[detail];
|
||||
const ceilingId = ceiling.id;
|
||||
|
||||
// Gefüllte Fläche, ohne Schraffur: die Decke wird im Grundriss frontal von
|
||||
// oben gesehen, nicht aufgeschnitten — Bauteil-Schraffuren gehören nur auf
|
||||
// Schnittflächen (siehe resolveCeilingSectionStyle/splitSlabLayers), nicht
|
||||
// auf die Aufsicht.
|
||||
const hatch = NO_HATCH;
|
||||
// Gefüllte Fläche mit der Ansichts-Schraffur: die Decke wird im Grundriss
|
||||
// frontal von unten gesehen, nicht aufgeschnitten — daher greift hier
|
||||
// NICHT die Schnitt-Schraffur (die gehört auf echte Schnittflächen, siehe
|
||||
// resolveCeilingSectionStyle/splitSlabLayers), sondern `viewHatchId`. Fehlt
|
||||
// sie (Default), bleibt die Aufsicht weiss. Im Detailgrad „grob" entfällt
|
||||
// die Schraffur ganz (nur Fläche + Umriss).
|
||||
const hatch =
|
||||
detail !== "grob" && comp?.viewHatchId
|
||||
? resolveHatch(project, comp.viewHatchId)
|
||||
: NO_HATCH;
|
||||
const solid = hatch.pattern === "solid";
|
||||
out.push({
|
||||
kind: "polygon",
|
||||
|
||||
@@ -283,11 +283,12 @@ function ResCell({
|
||||
|
||||
// ── Bauteile (Components) ──────────────────────────────────────────────────
|
||||
|
||||
// Spalten: Name | Farbe | Schraffur | Prio | Textur | Material | (löschen).
|
||||
// Spalten: Name | Farbe | Schnittschraffur | Ansichtsschraffur | Prio | Textur | Material | (löschen).
|
||||
const COMPONENT_COLUMNS: ResColumn[] = [
|
||||
{ titleKey: "resources.col.name" },
|
||||
{ titleKey: "resources.col.color" },
|
||||
{ titleKey: "resources.col.hatch" },
|
||||
{ titleKey: "resources.col.viewHatch" },
|
||||
{
|
||||
titleKey: "resources.col.prio",
|
||||
align: "right",
|
||||
@@ -298,7 +299,7 @@ const COMPONENT_COLUMNS: ResColumn[] = [
|
||||
{ titleKey: "" },
|
||||
];
|
||||
const COMPONENT_TEMPLATE =
|
||||
"minmax(120px, 1fr) auto minmax(120px, 0.8fr) 64px minmax(90px, 0.7fr) minmax(130px, 0.9fr) 36px";
|
||||
"minmax(120px, 1fr) auto minmax(120px, 0.8fr) minmax(120px, 0.8fr) 64px minmax(90px, 0.7fr) minmax(130px, 0.9fr) 36px";
|
||||
|
||||
/**
|
||||
* Material-Zelle der Bauteil-Tabelle: ein Button, der den aktuellen Material-
|
||||
@@ -766,6 +767,11 @@ function ComponentRow({
|
||||
onDelete: () => void;
|
||||
}) {
|
||||
const hatchOptions = hatches.map((h) => ({ value: h.id, label: h.name }));
|
||||
// Ansichts-Schraffur ist optional; Leer-Eintrag = keine Schraffur (weiss).
|
||||
const viewHatchOptions = [
|
||||
{ value: "", label: t("resources.viewHatch.none") },
|
||||
...hatchOptions,
|
||||
];
|
||||
return (
|
||||
<ResRow>
|
||||
<ResCell>
|
||||
@@ -788,6 +794,13 @@ function ComponentRow({
|
||||
options={hatchOptions}
|
||||
/>
|
||||
</ResCell>
|
||||
<ResCell>
|
||||
<SelectField
|
||||
value={component.viewHatchId ?? ""}
|
||||
onChange={(viewHatchId) => onPatch({ viewHatchId: viewHatchId || undefined })}
|
||||
options={viewHatchOptions}
|
||||
/>
|
||||
</ResCell>
|
||||
<ResCell align="right" emphasis>
|
||||
<NumberField
|
||||
value={component.joinPriority}
|
||||
|
||||
Reference in New Issue
Block a user