গবেষণা সমীক্ষা: ব্লকলি
স্টার্ট সার্ভে নিয়ে আপনার অভিজ্ঞতা সম্পর্কে আমাদের বলুন
ব্লকলি > IMetricsManager > getContentMetrics
IMetricsManager.getContentMetrics() পদ্ধতি
পিক্সেল বা ওয়ার্কস্পেস স্থানাঙ্কে বিষয়বস্তু মেট্রিক্স পায়। বিষয়বস্তু এলাকা হল একটি আয়তক্ষেত্র যা ওয়ার্কস্পেসে (ওয়ার্কস্পেস মন্তব্য এবং ব্লক) সমস্ত শীর্ষ আবদ্ধ উপাদানের চারপাশে।
স্বাক্ষর:
getContentMetrics(opt_getWorkspaceCoordinates?: boolean): ContainerRegion;
পরামিতি
প্যারামিটার | টাইপ | বর্ণনা |
---|
opt_getWorkspaceCoordinates | বুলিয়ান | (ঐচ্ছিক) ওয়ার্কস্পেস স্থানাঙ্কে বিষয়বস্তু মেট্রিক্স পেতে সত্য, পিক্সেল স্থানাঙ্কে পেতে মিথ্যা। |
রিটার্ন:
ধারক অঞ্চল
কন্টেন্ট কন্টেনার জন্য মেট্রিক্স.
অন্য কিছু উল্লেখ না করা থাকলে, এই পৃষ্ঠার কন্টেন্ট Creative Commons Attribution 4.0 License-এর অধীনে এবং কোডের নমুনাগুলি Apache 2.0 License-এর অধীনে লাইসেন্স প্রাপ্ত। আরও জানতে, Google Developers সাইট নীতি দেখুন। Java হল Oracle এবং/অথবা তার অ্যাফিলিয়েট সংস্থার রেজিস্টার্ড ট্রেডমার্ক।
2025-01-10 UTC-তে শেষবার আপডেট করা হয়েছে।
[null,null,["2025-01-10 UTC-তে শেষবার আপডেট করা হয়েছে।"],[[["The `getContentMetrics()` method calculates the size and position of the area containing all blocks and comments on a Blockly workspace."],["It allows you to retrieve these measurements in either pixel or workspace coordinates by using the optional `opt_getWorkspaceCoordinates` parameter."],["The method returns a `ContainerRegion` object which holds the calculated dimensions and position of the content area."]]],["The `getContentMetrics()` method retrieves content metrics, representing a rectangle around all top-level elements (blocks and comments) on the workspace. It accepts an optional boolean parameter, `opt_getWorkspaceCoordinates`. When `true`, it returns metrics in workspace coordinates; when `false` or omitted, it returns metrics in pixel coordinates. The method's output is a `ContainerRegion` object, containing the content container's metrics.\n"]]