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

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

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

    1. <tfoot id='Na4Hb'></tfoot>

        <legend id='Na4Hb'><style id='Na4Hb'><dir id='Na4Hb'><q id='Na4Hb'></q></dir></style></legend>
          <bdo id='Na4Hb'></bdo><ul id='Na4Hb'></ul>
      1. 如何大寫Android EditText中的每個(gè)字母?

        How to capitalize every letter in an Android EditText?(如何大寫Android EditText中的每個(gè)字母?)

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

          <tbody id='W223M'></tbody>
          <legend id='W223M'><style id='W223M'><dir id='W223M'><q id='W223M'></q></dir></style></legend>
            <tfoot id='W223M'></tfoot>

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

                  本文介紹了如何大寫Android EditText中的每個(gè)字母?的處理方法,對大家解決問題具有一定的參考價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)吧!

                  問題描述

                  我有一個(gè)這樣的editTexts數(shù)組:

                  I have an array of editTexts which I make like this:

                          inputs[i] = new EditText(this);
                          inputs[i].setWidth(376);
                          inputs[i].setInputType(InputType.TYPE_TEXT_FLAG_CAP_CHARACTERS);
                          tFields.addView(inputs[i]);
                  

                  我希望每個(gè)字符都大寫.現(xiàn)在,第一個(gè)單詞的第一個(gè)字母是小寫的,然后后面的所有字符都是大寫的.我可以在用戶輸入完成后將其轉(zhuǎn)換為大寫,但這并不是我真正想要的.有沒有辦法讓這些字段按照我想要的方式運(yùn)行?

                  I want every character to be capitalized. Right now, the first letter of the first word is lowercase, then all the characters afterwords are upper case. I can take what the user inputs after they are done and convert that to uppercase, but that's not really what I'm going for. Is there a way to get these fields to behave the way I want them to?

                  推薦答案

                  你也需要告訴它來自class"文本:

                  You need to tell it it's from the "class" text as well:

                  inputs[i] = new EditText(this);
                  inputs[i].setWidth(376);
                  inputs[i].setInputType(InputType.TYPE_CLASS_TEXT | InputType.TYPE_TEXT_FLAG_CAP_CHARACTERS);
                  tFields.addView(inputs[i]);
                  

                  輸入類型是一個(gè)位掩碼.您可以通過放置 | 來組合標(biāo)志.(管道)字符在中間,它代表 OR 邏輯函數(shù),即使在像這樣的位掩碼中使用它意味著這個(gè)標(biāo)志和那個(gè)另一個(gè)標(biāo)志".

                  The input type is a bitmask. You can combine the flags by putting the | (pipe) character in the middle, which stands for the OR logic function, even though when used in a bitmask like this it means "this flag AND that other flag".

                  (此答案與 Robin 的答案相同,但沒有幻數(shù)",這是您可以在代碼中放入的最糟糕的事情之一.Android API 具有常量,請使用它們而不是復(fù)制值并冒最終破壞代碼的風(fēng)險(xiǎn).)

                  (This answer is the same as Robin's but without "magic numbers", one of the worst things you can put in your code. The Android API has constants, use them instead of copying the values and risking to eventually break the code.)

                  這篇關(guān)于如何大寫Android EditText中的每個(gè)字母?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網(wǎng)!

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

                  相關(guān)文檔推薦

                  How can I detect integer overflow on 32 bits int?(如何檢測 32 位 int 上的整數(shù)溢出?)
                  Local variables before return statements, does it matter?(return 語句之前的局部變量,這有關(guān)系嗎?)
                  How to convert Integer to int?(如何將整數(shù)轉(zhuǎn)換為整數(shù)?)
                  How do I create an int array with randomly shuffled numbers in a given range(如何在給定范圍內(nèi)創(chuàng)建一個(gè)隨機(jī)打亂數(shù)字的 int 數(shù)組)
                  Inconsistent behavior on java#39;s ==(java的行為不一致==)
                  Why is Java able to store 0xff000000 as an int?(為什么 Java 能夠?qū)?0xff000000 存儲為 int?)

                  • <small id='8TNS0'></small><noframes id='8TNS0'>

                    <legend id='8TNS0'><style id='8TNS0'><dir id='8TNS0'><q id='8TNS0'></q></dir></style></legend>

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

                        <tfoot id='8TNS0'></tfoot>

                            <bdo id='8TNS0'></bdo><ul id='8TNS0'></ul>
                            主站蜘蛛池模板: 久久久蜜桃| 一区二区在线看 | 男人电影天堂 | 金莲网| 国产成人精品综合 | 午夜ww| 成人性视频免费网站 | 亚洲一区二区三区在线 | 国产精品亚洲成在人线 | 亚洲欧美中文字幕在线观看 | 精品久久久久香蕉网 | 视频二区在线观看 | 亚洲视频一区 | 中文字幕久久精品 | 香蕉婷婷 | 国产精品视频久久 | 狠狠亚洲 | 国产精品一区二区在线 | 激情五月激情综合网 | 国产精品永久久久久 | 久久久久电影 | 成人区精品一区二区婷婷 | 亚洲精品日韩综合观看成人91 | 美日韩视频 | 日韩精品一区二区三区视频播放 | 高清色| 狠狠综合网 | 免费黄篇| 97伦理最新伦理 | 一本一道久久a久久精品综合蜜臀 | 中文字幕成人在线 | 日日夜夜操天天干 | 国产精品久久久久久久久大全 | 国产精品久久久久久av公交车 | 99婷婷 | 久久免费国产 | 国产综合视频 | 色视频www在线播放国产人成 | 99久久精品免费看国产免费软件 | 四虎影院久久 | 国产精品3区 |