久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

    <legend id='x7yZ7'><style id='x7yZ7'><dir id='x7yZ7'><q id='x7yZ7'></q></dir></style></legend>
  • <tfoot id='x7yZ7'></tfoot>
  • <small id='x7yZ7'></small><noframes id='x7yZ7'>

      <i id='x7yZ7'><tr id='x7yZ7'><dt id='x7yZ7'><q id='x7yZ7'><span id='x7yZ7'><b id='x7yZ7'><form id='x7yZ7'><ins id='x7yZ7'></ins><ul id='x7yZ7'></ul><sub id='x7yZ7'></sub></form><legend id='x7yZ7'></legend><bdo id='x7yZ7'><pre id='x7yZ7'><center id='x7yZ7'></center></pre></bdo></b><th id='x7yZ7'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='x7yZ7'><tfoot id='x7yZ7'></tfoot><dl id='x7yZ7'><fieldset id='x7yZ7'></fieldset></dl></div>
        <bdo id='x7yZ7'></bdo><ul id='x7yZ7'></ul>

      1. Android:如何創建帶有滾動標題的對話框?

        Android: How to create a Dialog with a Scrolling title?(Android:如何創建帶有滾動標題的對話框?)

          <small id='VadXW'></small><noframes id='VadXW'>

          • <legend id='VadXW'><style id='VadXW'><dir id='VadXW'><q id='VadXW'></q></dir></style></legend>

            1. <tfoot id='VadXW'></tfoot>
                  <tbody id='VadXW'></tbody>
                  <bdo id='VadXW'></bdo><ul id='VadXW'></ul>

                  <i id='VadXW'><tr id='VadXW'><dt id='VadXW'><q id='VadXW'><span id='VadXW'><b id='VadXW'><form id='VadXW'><ins id='VadXW'></ins><ul id='VadXW'></ul><sub id='VadXW'></sub></form><legend id='VadXW'></legend><bdo id='VadXW'><pre id='VadXW'><center id='VadXW'></center></pre></bdo></b><th id='VadXW'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='VadXW'><tfoot id='VadXW'></tfoot><dl id='VadXW'><fieldset id='VadXW'></fieldset></dl></div>
                  本文介紹了Android:如何創建帶有滾動標題的對話框?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

                  問題描述

                  好的,我已經閱讀了 And Dev 網站上的自定義對話框說明http://developer.android.com/guide/topics/ui/dialogs.html#CustomDialog

                  Ok so I've read the Custom Dialog explanation on the And Dev website http://developer.android.com/guide/topics/ui/dialogs.html#CustomDialog

                  它向您展示了如何制作自定義對話框,而不是如何自定義標題!

                  It show's you how to make a custom dialog, but not how to customise the title!

                  基本上我的標題太長了,我希望它可以滾動(如 textview),或者更好的是仍然有一個選框"效果,我認為它被稱為.

                  Basically my title is too long and I want it to scroll (like textview) or better still have a 'marquee' effect i think it's called.

                  或者如果我不能讓它滾動,給它更多的空間來換行!

                  Or if I can't make it scroll, give it more space to wrap onto more lines!

                  任何想法,我都不抱太大希望,因為它不在 android.dev 上 :-(

                  Any ideas, I don't hold out much hope as it's not on android.dev :-(

                  推薦答案

                  自定義窗口(以及對話框)標題可以通過請求窗口功能 CUSTOM_TITLE 來完成,這必須在 setContentView 之前完成.

                  Customizig window (and thus also dialog) titles can be done by requesting the window feature CUSTOM_TITLE, which must be done before setContentView.

                  因此,在您的 Dialog/Activity 子類 onCreate() 中,調用以下代碼:

                  So in your Dialog / Activity subclasses onCreate(), call the following:

                  super.onCreate(savedInstance);
                  requestWindowFeature(Window.FEATURE_CUSTOM_TITLE); // <- insert this
                  

                  然后,您的 setContentView 之后,執行以下操作:

                  Then, after your setContentView, do this:

                  setContentView(R.layout.main);
                  getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.custom_title); // <- insert this
                  

                  布局通常可以包含您想要的任何內容.對于選取框文本控件.例如這樣做:

                  The layout can generally contain anything you want. For a marquee text control. e.g. do this:

                  布局/custom_title.xml:

                  layout/custom_title.xml:

                  <FrameLayout android:id="@+id/FrameLayout01" 
                      android:layout_width="fill_parent" 
                      android:layout_height="fill_parent" 
                      xmlns:android="http://schemas.android.com/apk/res/android"
                      >
                      <TextView android:id="@+id/caption_text" 
                          android:layout_height="wrap_content" 
                          android:layout_width="fill_parent" 
                          android:text="This is a very very long text that will not fit into a caption regularly, so it will be displayed using marquee..." 
                          android:lines="1"
                          android:focusable="true"
                          android:focusableInTouchMode="true"
                          android:scrollHorizontally="true" 
                          android:marqueeRepeatLimit="marquee_forever" 
                          android:ellipsize="marquee"
                          ></TextView>
                  </FrameLayout>
                  

                  由于選取框功能的一些限制,必須使文本視圖具有焦點,并且只有在獲得焦點時才會滾動(最初應該是這樣).

                  Due to some constraints with the marquee feature, the text view has to be made focusable and it will only be scrolling when focused (which it initially should be).

                  這篇關于Android:如何創建帶有滾動標題的對話框?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

                  【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

                  相關文檔推薦

                  Get user#39;s current location using GPS(使用 GPS 獲取用戶的當前位置)
                  IllegalArgumentException thrown by requestLocationUpdate()(requestLocationUpdate() 拋出的 IllegalArgumentException)
                  How reliable is LocationManager#39;s getLastKnownLocation and how often is it updated?(LocationManager 的 getLastKnownLocation 有多可靠,多久更新一次?)
                  How to detect Location Provider ? GPS or Network Provider(如何檢測位置提供者?GPS 或網絡提供商)
                  Get current location during app launch(在應用啟動期間獲取當前位置)
                  locationManager.getLastKnownLocation() return null(locationManager.getLastKnownLocation() 返回 null)

                  • <tfoot id='tv3Tf'></tfoot>
                      <i id='tv3Tf'><tr id='tv3Tf'><dt id='tv3Tf'><q id='tv3Tf'><span id='tv3Tf'><b id='tv3Tf'><form id='tv3Tf'><ins id='tv3Tf'></ins><ul id='tv3Tf'></ul><sub id='tv3Tf'></sub></form><legend id='tv3Tf'></legend><bdo id='tv3Tf'><pre id='tv3Tf'><center id='tv3Tf'></center></pre></bdo></b><th id='tv3Tf'></th></span></q></dt></tr></i><div class="qwawimqqmiuu" id='tv3Tf'><tfoot id='tv3Tf'></tfoot><dl id='tv3Tf'><fieldset id='tv3Tf'></fieldset></dl></div>

                      <legend id='tv3Tf'><style id='tv3Tf'><dir id='tv3Tf'><q id='tv3Tf'></q></dir></style></legend>
                        <bdo id='tv3Tf'></bdo><ul id='tv3Tf'></ul>

                          1. <small id='tv3Tf'></small><noframes id='tv3Tf'>

                              <tbody id='tv3Tf'></tbody>
                          2. 主站蜘蛛池模板: 久久久久久久久久一区二区 | xxxcom在线观看 | 日韩一级免费看 | 免费黄色大片 | 色伊人 | 久久国产精品久久久久久 | 黄色片网站国产 | 国产精品毛片一区二区在线看 | 国产亚洲精品综合一区 | 国产一区二区三区四区 | 手机看黄av免费网址 | 国产一区二区黑人欧美xxxx | 精品久久久久久久久久久下田 | 欧美极品在线观看 | 亚洲精品国产精品国自产在线 | aaa级片| 精品国产乱码久久久久久丨区2区 | 亚洲高清在线观看 | 精品欧美乱码久久久久久1区2区 | 日韩性生活网 | 麻豆一区| 中文字幕 亚洲一区 | 欧美中国少妇xxx性高请视频 | 国产一区二区三区视频 | 草草视频在线免费观看 | 色综合久久久 | 精品无码久久久久国产 | 中文字幕人成人 | 亚洲人成人一区二区在线观看 | 日韩一区二区三区在线视频 | 天天想天天干 | 在线观看日本高清二区 | 亚洲天堂中文字幕 | 亚洲交性 | 国产综合久久 | 国产成人精品一区二区在线 | 亚洲一区二区黄 | 国产精品一区二区三区在线 | 日韩中文在线观看 | 色综合99| 欧美国产日韩在线观看成人 |