zoukankan      html  css  js  c++  java
  • 怎么设置输入的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 ());
查看全文
  • 相关阅读:
    U9在SQL Server上的性能优化经验(转述) — 之 分页
    家里买了XBOX 360 Kinect
    哦,真是“不幸”的消息
    U9在SQL Server上的性能优化经验(转述) — 之 包含列索引
    Silverlight 4处理StartWith的BUG
    IIS HTTP重定向配置、参数设置
    【代码保留】怎样添加一个多选搜索引擎
    NSLog 使用
    ObjectiveC(IOS)推荐的属性读写方法
    16进制颜色(html颜色值)字符串转为UIColor
  • 原文地址:https://www.cnblogs.com/ldxsuanfa/p/10734112.html
  • Copyright © 2011-2022 走看看