संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
ब्लॉकली > blockRendering > RenderInfo > getElemCenterline_
ब्लॉक रेंडरिंग.RenderInfo.getElemCenterline_() तरीका
किसी रेंडर की गई पंक्ति में, एलिमेंट की सेंटरलाइन की गणना करना. लागू किया गया यह बेस, सेंटरलाइन को लाइन के बीच में वर्टिकल तौर पर दिखाता है. इसमें कोई खास केस नहीं होता. आपको सबसे ऊपर और सबसे नीचे की पंक्तियों को हैंडल करने के लिए, ज़्यादा से ज़्यादा लॉजिक की ज़रूरत होगी.
हस्ताक्षर:
protected getElemCenterline_(row: Row, elem: Measurable): number;
पैरामीटर
लौटाए जाने वाले प्रॉडक्ट:
संख्या
दिए गए एलिमेंट की पसंदीदा सेंटरलाइन, ब्लॉक के ऊपर बाईं ओर से ऑफ़सेट के तौर पर.
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-07-25 (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-07-25 (UTC) को अपडेट किया गया."],[],["The `getElemCenterline_()` method calculates the vertical centerline of an element within a rendered row. It positions the centerline at the row's vertical midpoint. The method takes a `Row` and a `Measurable` element as input. It returns a number representing the element's centerline offset from the block's top-left corner. Custom implementations are often needed to adjust positioning for specific rows.\n"]]