Package sun.text

Examples of sun.text.CodePointIterator


                if (font.canDisplayUpTo(text, start, limit) != -1) {
                    return null;
                }
            } else {
                FontResolver resolver = FontResolver.getInstance();
                CodePointIterator iter = CodePointIterator.create(text, start, limit);
                int fontIndex = resolver.nextFontRunIndex(iter);
                if (iter.charIndex() == limit) {
                    font = resolver.getFont(fontIndex, attributes);
                }
            }
        }
View Full Code Here


     * font runs for each.
     */
    private void addFonts(char[] chars, Map attributes, int start, int limit) {
   
        FontResolver resolver = FontResolver.getInstance();
  CodePointIterator iter = CodePointIterator.create(chars, start, limit);
  for (int runStart = iter.charIndex(); runStart < limit; runStart = iter.charIndex()) {
      int fontIndex = resolver.nextFontRunIndex(iter);
            addFont(resolver.getFont(fontIndex, attributes), runStart);
        }
    }
View Full Code Here

     * @param start the start of the range of characters to test
     * @param limit the limit of the range of characters to test
     * @return true if the range of characters requires bidi analysis
     */
    public static boolean requiresBidi(char[] text, int start, int limit) {
  CodePointIterator cpi = CodePointIterator.create(text, start, limit);
  for (int cp = cpi.next(); cp != CodePointIterator.DONE; cp = cpi.next()) {
      if (cp > 0x0590) {
    int dc = nativeGetDirectionCode(cp);
    if ((RMASK & (1 << dc)) != 0) {
        return true;
    }
View Full Code Here

     */
    private void addFonts(char[] chars, Map<? extends Attribute, ?> attributes,
                          int start, int limit) {

        FontResolver resolver = FontResolver.getInstance();
        CodePointIterator iter = CodePointIterator.create(chars, start, limit);
        for (int runStart = iter.charIndex(); runStart < limit; runStart = iter.charIndex()) {
            int fontIndex = resolver.nextFontRunIndex(iter);
            addFont(resolver.getFont(fontIndex, attributes), runStart);
        }
    }
View Full Code Here

     * font runs for each.
     */
    private void addFonts(char[] chars, Map attributes, int start, int limit) {

        FontResolver resolver = FontResolver.getInstance();
        CodePointIterator iter = CodePointIterator.create(chars, start, limit);
        for (int runStart = iter.charIndex(); runStart < limit; runStart = iter.charIndex()) {
            int fontIndex = resolver.nextFontRunIndex(iter);
            addFont(resolver.getFont(fontIndex, attributes), runStart);
        }
    }
View Full Code Here

                if (font.canDisplayUpTo(text, start, limit) != -1) {
                    return null;
                }
            } else {
                FontResolver resolver = FontResolver.getInstance();
                CodePointIterator iter = CodePointIterator.create(text, start, limit);
                int fontIndex = resolver.nextFontRunIndex(iter);
                if (iter.charIndex() == limit) {
                    font = resolver.getFont(fontIndex, attributes);
                }
            }
        }
View Full Code Here

     * font runs for each.
     */
    private void addFonts(char[] chars, Map attributes, int start, int limit) {

        FontResolver resolver = FontResolver.getInstance();
        CodePointIterator iter = CodePointIterator.create(chars, start, limit);
        for (int runStart = iter.charIndex(); runStart < limit; runStart = iter.charIndex()) {
            int fontIndex = resolver.nextFontRunIndex(iter);
            addFont(resolver.getFont(fontIndex, attributes), runStart);
        }
    }
View Full Code Here

     * @param start the start of the range of characters to test
     * @param limit the limit of the range of characters to test
     * @return true if the range of characters requires bidi analysis
     */
    public static boolean requiresBidi(char[] text, int start, int limit) {
        CodePointIterator cpi = CodePointIterator.create(text, start, limit);
        for (int cp = cpi.next(); cp != CodePointIterator.DONE; cp = cpi.next()) {
            if (cp > 0x0590) {
                int dc = nativeGetDirectionCode(cp);
                if ((RMASK & (1 << dc)) != 0) {
                    return true;
                }
View Full Code Here

TOP

Related Classes of sun.text.CodePointIterator

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.