टच जेस्चर का इस्तेमाल करें
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
लिखने की सुविधा आज़माएं
Android के लिए, Jetpack Compose को यूज़र इंटरफ़ेस (यूआई) टूलकिट के तौर पर इस्तेमाल करने का सुझाव दिया जाता है. Compose में टच और इनपुट का इस्तेमाल करने का तरीका जानें.
इस दस्तावेज़ में, ऐसे ऐप्लिकेशन बनाने का तरीका बताया गया है जिनमें उपयोगकर्ता, टच जेस्चर का इस्तेमाल करके ऐप्लिकेशन से इंटरैक्ट कर सकते हैं. Android, जेस्चर बनाने और उनका पता लगाने में आपकी मदद करने के लिए कई तरह के एपीआई उपलब्ध कराता है.
हालांकि, आपके ऐप्लिकेशन को बुनियादी कार्रवाइयों के लिए टच जेस्चर पर निर्भर नहीं रहना चाहिए. ऐसा इसलिए, क्योंकि हो सकता है कि सभी उपयोगकर्ताओं के लिए, सभी संदर्भों में जेस्चर उपलब्ध न हों. हालांकि, अपने ऐप्लिकेशन में टच-आधारित इंटरैक्शन जोड़ने से, ऐप्लिकेशन के इस्तेमाल और उसकी अपील में काफ़ी बढ़ोतरी हो सकती है.
उपयोगकर्ताओं को एक जैसा और आसान अनुभव देने के लिए, आपके ऐप्लिकेशन को टच जेस्चर के लिए, Android के मान्य नियमों का पालन करना होगा. मटीरियल डिज़ाइन के जेस्चर दस्तावेज़ में, Android ऐप्लिकेशन में सामान्य जेस्चर इस्तेमाल करने का तरीका बताया गया है. इसके अलावा, Material Motion देखें.
इस विषय के बारे में ज़्यादा जानने के लिए, इससे जुड़ी ये गाइड पढ़ें:
विषय
-
सामान्य जेस्चर का पता लगाना
-
GestureDetector
का इस्तेमाल करके, स्क्रोल करने, फ़्लिंग करने, और दो बार टैप करने जैसे बुनियादी टच जेस्चर का पता लगाने का तरीका जानें.
-
टच और पॉइंटर की गतिविधियों को ट्रैक करना
-
गतिविधि को ट्रैक करने का तरीका जानें.
-
स्क्रोल करने के जेस्चर को ऐनिमेट करना
-
टच इवेंट के जवाब में स्क्रोलिंग ऐनिमेशन बनाने के लिए, स्क्रोलर—
Scroller
या
OverScroller
—का
इस्तेमाल करने का तरीका जानें.
-
मल्टी-टच जेस्चर हैंडल करना
-
एक से ज़्यादा पॉइंटर (उंगली) से किए जाने वाले जेस्चर (हाव-भाव) का पता लगाने का तरीका जानें.
-
खींचकर छोड़ना और स्केल करना
-
स्क्रीन को छूकर खींचने और ज़ूम करने की सुविधा लागू करने का तरीका जानें.
- ViewGroup में टच इवेंट मैनेज करना
ViewGroup
में टच इवेंट मैनेज करने का तरीका जानें, ताकि यह पक्का किया जा सके कि टच इवेंट को उनके टारगेट व्यू में सही तरीके से भेजा गया है.
इस पेज पर मौजूद कॉन्टेंट और कोड सैंपल कॉन्टेंट के लाइसेंस में बताए गए लाइसेंस के हिसाब से हैं. Java और OpenJDK, Oracle और/या इससे जुड़ी हुई कंपनियों के ट्रेडमार्क या रजिस्टर किए हुए ट्रेडमार्क हैं.
आखिरी बार 2025-07-27 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-07-27 (UTC) को अपडेट किया गया."],[],[],null,["# Use touch gestures\n\nTry the Compose way \nJetpack Compose is the recommended UI toolkit for Android. Learn how to use touch and input in Compose. \n[Gestures →](/jetpack/compose/touch-input/pointer-input) \n\nThis document describes how to write apps that let users interact with an app using touch\ngestures. Android provides a variety of APIs to help you create and detect gestures.\n\nAlthough your app must not depend on touch gestures for basic behaviors---since the gestures\nmight not be available to all users in all contexts---adding touch-based interaction to your app\ncan greatly increase its usefulness and appeal.\n\nTo provide users with a consistent, intuitive experience, your app must follow the accepted\nAndroid conventions for touch gestures. The\n[Material Design Gestures](https://material.io/design/interaction/gestures.html)\ndocument shows you how to use common gestures in Android apps. Also, see\n[Material Motion](https://material.io/guidelines/motion/material-motion.html).\n\nFor more information about this topic, read the following related guides:\n\n- [Input events overview](/guide/topics/ui/ui-events)\n- [Sensors overview](/guide/topics/sensors/sensors_overview)\n- [Make a custom view\n interactive](/training/custom-views/making-interactive)\n\nTopics\n------\n\n\n**[Detect common gestures](/develop/ui/views/touch-and-input/gestures/detector)**\n:\n Learn how to detect basic touch gestures, such as scrolling, flinging, and double-tapping,\n using\n [GestureDetector](/reference/android/view/GestureDetector).\n\n\n**[Track touch and pointer movements](/develop/ui/views/touch-and-input/gestures/movement)**\n:\n Learn how to track movement.\n\n\n**[Animate a scroll gesture](/develop/ui/views/touch-and-input/gestures/scroll)**\n:\n Learn how to use\n scrollers---[Scroller](/reference/android/widget/Scroller)\n or\n [OverScroller](/reference/android/widget/OverScroller)---to\n produce a scrolling animation in response to a touch event.\n\n\n**[Handle multi-touch gestures](/develop/ui/views/touch-and-input/gestures/multi)**\n:\n Learn how to detect multi-pointer (finger) gestures.\n\n\n**[Drag and scale](/develop/ui/views/touch-and-input/gestures/scale)**\n:\n Learn how to implement touch-based dragging and scaling.\n\n**[Manage touch events in a ViewGroup](/develop/ui/views/touch-and-input/gestures/viewgroup)**\n: Learn how to manage touch events in a\n [ViewGroup](/reference/android/view/ViewGroup) to ensure that\n touch events are correctly dispatched to their target views."]]