Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import android.graphics.Typeface;

import android.text.SpannableString;
import android.text.style.StyleSpan;

public class Main {
    public static CharSequence setTextStyleNormal(CharSequence text) {
        final StyleSpan style = new StyleSpan(Typeface.NORMAL);
        final SpannableString str = new SpannableString(text);
        str.setSpan(style, 0, text.length(), 0);

        return str;
    }
}