סקר מחקר: נשמח לשמוע על החוויה שלך עם Blockly
לפתיחת הסקר
קל לארגן דפים בעזרת אוספים
אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
blockly > blockRendering > ConstantProvider > createDom
השיטה blockRendering.ConstantProvider.createDom()
יוצרים את כל רכיבי ה-DOM שנדרשים למעבד הגרפיקה הזה (מסננים, דפוסים וכו').
Signature:
createDom(svg: SVGElement, tagName: string, selector: string, injectionDivIfIsParent?: HTMLElement): void;
פרמטרים
פרמטר |
סוג |
תיאור |
svg |
SVGElement |
שורש קובץ ה-SVG של סביבת העבודה. |
tagName |
מחרוזת |
השם שישמש בתג הסגנון של ה-CSS. |
בורר |
מחרוזת |
סלקטור ה-CSS שבו רוצים להשתמש. |
injectionDivIfIsParent |
HTMLElement |
(אופציונלי) ה-div שמכיל את סביבת העבודה של ההורה ואת כל סביבות העבודה הקשורות ואת מאגרי הרכיבים, אם ה-renderer הזה מיועד לסביבת העבודה של ההורה. משתני CSS שמייצגים דפוסי SVG יהיו ברמת הקונטיינר הזה. לא צריך לשנות את משתני ה-CSS שנוצרו על ידי החשבון ההורה במרחבי העבודה הצאצאים, ולכן אין להם צורך בגישה ל-div ההזרקה. |
החזרים:
לא תקף
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2025-05-16 (שעון UTC).
[[["התוכן קל להבנה","easyToUnderstand","thumb-up"],["התוכן עזר לי לפתור בעיה","solvedMyProblem","thumb-up"],["סיבה אחרת","otherUp","thumb-up"]],[["חסרים לי מידע או פרטים","missingTheInformationINeed","thumb-down"],["התוכן מורכב מדי או עם יותר מדי שלבים","tooComplicatedTooManySteps","thumb-down"],["התוכן לא עדכני","outOfDate","thumb-down"],["בעיה בתרגום","translationIssue","thumb-down"],["בעיה בדוגמאות/בקוד","samplesCodeIssue","thumb-down"],["סיבה אחרת","otherDown","thumb-down"]],["עדכון אחרון: 2025-05-16 (שעון UTC)."],[[["The `blockRendering.ConstantProvider.createDom()` method generates necessary DOM elements within the workspace's SVG for the renderer, such as filters and patterns."],["It accepts the workspace's SVG root, a style tag name, and a CSS selector as parameters to facilitate DOM element creation."],["This method modifies the SVG structure but does not return any specific value."]]],["The `createDom()` method, part of `blockRendering.ConstantProvider`, generates necessary DOM elements for the renderer, such as filters and patterns. It accepts three parameters: `svg` (the workspace's SVG root), `tagName` (CSS style tag name), and `selector` (CSS selector). This method does not return anything, and its primary function is to set up DOM elements within the workspace's SVG structure.\n"]]