• 怎么设置输入的EditText字母自己主动大写


    版权声明:本文为博主原创文章,未经博主同意不得转载。

    https://blog.csdn.net/t80t90s/article/details/25048917

    复于: 2013-09-06 09:06:25
    package com.gainko.helper;

    import android.text.method.ReplacementTransformationMethod;

    /**
     * @author Ivan
     * 
     */
    public class AllCapTransformationMethod extends ReplacementTransformationMethod {

    @Override
    protected char[] getOriginal() {
    char[] aa = { 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z' };
    return aa;
    }

    @Override
    protected char[] getReplacement() {
    char[] cc = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z' };
    return cc;
    }

    }

    ///
    editext.setTransformationMethod(new AllCapTransformationMethod ());
  • 相关阅读:
    Palindrome Partitioning
    triangle
    Populating Next Right Pointers in Each Node(I and II)
    分苹果(网易)
    Flatten Binary Tree to Linked List
    Construct Binary Tree from Inorder and Postorder Traversal(根据中序遍历和后序遍历构建二叉树)
    iOS系统navigationBar背景色,文字颜色处理
    登录,注销
    ios 文字上下滚动效果Demo
    经常崩溃就是数组字典引起的
  • 原文地址:https://www.cnblogs.com/ldxsuanfa/p/10734112.html
  • Copyright © 2020-2023  润新知