টুলটিপস
সেভ করা পৃষ্ঠা গুছিয়ে রাখতে 'সংগ্রহ' ব্যবহার করুন
আপনার পছন্দ অনুযায়ী কন্টেন্ট সেভ করুন ও সঠিক বিভাগে রাখুন।
রচনা পদ্ধতি চেষ্টা করুন
জেটপ্যাক কম্পোজ হল Android এর জন্য প্রস্তাবিত UI টুলকিট। কম্পোজে উপাদান যোগ করতে শিখুন।
একটি টুলটিপ হল একটি ছোট বর্ণনামূলক বার্তা যা একটি দৃশ্যের কাছাকাছি প্রদর্শিত হয় যখন ব্যবহারকারীরা ভিউটি দীর্ঘক্ষণ চাপ দেয় বা এটির উপর তাদের মাউস ঘোরায়। এটি উপযোগী হয় যখন আপনার অ্যাপ লেআউটে স্থান বাঁচাতে একটি ক্রিয়া বা তথ্যের অংশ উপস্থাপন করতে একটি আইকন ব্যবহার করে। এই পৃষ্ঠাটি আপনাকে Android 8.0 (API স্তর 26) এবং উচ্চতর সংস্করণে এই টুলটিপগুলি কীভাবে যুক্ত করতে হয় তা দেখায়৷
কিছু পরিস্থিতিতে, যেমন উৎপাদনশীলতা অ্যাপে, ধারণা এবং ক্রিয়াকলাপের জন্য একটি বর্ণনামূলক পদ্ধতির প্রয়োজন। আপনি একটি বর্ণনামূলক বার্তা প্রদর্শন করতে টুলটিপ ব্যবহার করতে পারেন, যেমন চিত্র 1-এ দেখানো হয়েছে।

চিত্র 1. একটি অ্যান্ড্রয়েড অ্যাপে প্রদর্শিত টুলটিপ।
কিছু স্ট্যান্ডার্ড উইজেট title
বা content description
বৈশিষ্ট্যের বিষয়বস্তুর উপর ভিত্তি করে টুলটিপ প্রদর্শন করে। Android 8.0 থেকে শুরু করে, আপনি অন্যান্য বৈশিষ্ট্যের মান নির্বিশেষে টুলটিপে প্রদর্শিত পাঠ্যটি নির্দিষ্ট করতে পারেন।
টুলটিপ পাঠ্য সেট করা হচ্ছে
আপনি setTooltipText()
পদ্ধতিতে কল করে একটি View
টুলটিপ পাঠ্যটি নির্দিষ্ট করতে পারেন। আপনি সংশ্লিষ্ট XML অ্যাট্রিবিউট বা API ব্যবহার করে tooltipText
বৈশিষ্ট্য সেট করতে পারেন।
আপনার XML ফাইলগুলিতে টুলটিপ পাঠ্যটি নির্দিষ্ট করতে, নিম্নলিখিত উদাহরণে দেখানো হিসাবে android:tooltipText
বৈশিষ্ট্যটি সেট করুন:
<android.support.design.widget.FloatingActionButton
android:id="@+id/fab"
android:tooltipText="Send an email" />
আপনার কোডে টুলটিপ টেক্সট নির্দিষ্ট করতে, নিম্নলিখিত উদাহরণে দেখানো হিসাবে setTooltipText(CharSequence)
পদ্ধতি ব্যবহার করুন:
কোটলিন
val fab: FloatingActionButton = findViewById(R.id.fab)
fab.tooltipText = "Send an email"
জাভা
FloatingActionButton fab = (FloatingActionButton) findViewById(R.id.fab);
fab.setTooltipText("Send an email");
API-এ একটি getTooltipText()
পদ্ধতিও রয়েছে যা আপনি tooltipText
সম্পত্তির মান পুনরুদ্ধার করতে ব্যবহার করতে পারেন।
অ্যান্ড্রয়েড tooltipText
প্রপার্টির মান প্রদর্শন করে যখন ব্যবহারকারীরা তাদের মাউসটি ভিউয়ের উপর ঘোরায় বা ভিউটি দীর্ঘক্ষণ চাপ দেয়।
এই পৃষ্ঠার কন্টেন্ট ও কোডের নমুনাগুলি Content License-এ বর্ণিত লাইসেন্সের অধীনস্থ। Java এবং OpenJDK হল Oracle এবং/অথবা তার অ্যাফিলিয়েট সংস্থার রেজিস্টার্ড ট্রেডমার্ক।
2025-08-26 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-08-26 UTC-তে শেষবার আপডেট করা হয়েছে।"],[],[],null,["Try the Compose way \nJetpack Compose is the recommended UI toolkit for Android. Learn how to add components in Compose. \n[Tooltip →](/develop/ui/compose/components/tooltip) \n\n\u003cbr /\u003e\n\nA tooltip is a small descriptive message that appears near a view when users\nlong press the view or hover their mouse over it. This is useful when your app\nuses an icon to represent an action or piece of information to save space in the\nlayout. This page shows you how to add these tooltips on Android 8.0 (API level\n26) and higher.\n\nSome scenarios, such as those in productivity apps, require a descriptive method\nof communicating ideas and actions. You can use tooltips to display a\ndescriptive message, as shown in figure 1.\n\n**Figure 1.** Tooltip displayed in an Android app.\n\nSome standard widgets display tooltips based on the content of the `title` or\n`content description` properties. Starting in Android 8.0, you can specify the\ntext displayed in the tooltip regardless of the value of other properties.\n\nSetting the tooltip text\n\nYou can specify the tooltip text in a [View](/reference/android/view/View) by calling the\n[setTooltipText()](/reference/android/view/View#setTooltipText(java.lang.CharSequence)) method. You can set\nthe `tooltipText` property using the corresponding XML attribute or API.\n\nTo specify the tooltip text in your XML files, set the [android:tooltipText](/reference/android/R.styleable#View_tooltipText) attribute, as shown\nin the following example: \n\n \u003candroid.support.design.widget.FloatingActionButton\n android:id=\"@+id/fab\"\n android:tooltipText=\"Send an email\" /\u003e\n\nTo specify the tooltip text in your code, use the [setTooltipText(CharSequence)](/reference/android/view/View#setTooltipText(java.lang.CharSequence)) method, as shown in the following example: \n\nKotlin \n\n```kotlin\nval fab: FloatingActionButton = findViewById(R.id.fab)\nfab.tooltipText = \"Send an email\"\n```\n\nJava \n\n```java\nFloatingActionButton fab = (FloatingActionButton) findViewById(R.id.fab);\nfab.setTooltipText(\"Send an email\");\n```\n\nThe API also includes a [getTooltipText()](/reference/android/view/View#getTooltipText()) method that\nyou can use to retrieve the value of the `tooltipText` property.\n\nAndroid displays the value of the `tooltipText` property when users hover their\nmouse over the view or long press the view."]]