Examples of CTFontScheme


Examples of org.openxmlformats.schemas.spreadsheetml.x2006.main.CTFontScheme

     *
     * @param scheme - FontScheme enum value
     * @see FontScheme
     */
    public void setScheme(FontScheme scheme) {
        CTFontScheme ctFontScheme = _ctFont.sizeOfSchemeArray() == 0 ? _ctFont.addNewScheme() : _ctFont.getSchemeArray(0);
        STFontScheme.Enum val = STFontScheme.Enum.forInt(scheme.getValue());
        ctFontScheme.setVal(val);
    }
View Full Code Here

Examples of org.openxmlformats.schemas.spreadsheetml.x2006.main.CTFontScheme

    assertEquals(FontFamily.MODERN.getValue(),xssfFont.getFamily());
  }

  public void testScheme() {
    CTFont ctFont=CTFont.Factory.newInstance();
    CTFontScheme scheme=ctFont.addNewScheme();
    scheme.setVal(STFontScheme.MAJOR);
    ctFont.setSchemeArray(0,scheme);

    XSSFFont font=new XSSFFont(ctFont);
    assertEquals(FontScheme.MAJOR,font.getScheme());
View Full Code Here

Examples of org.openxmlformats.schemas.spreadsheetml.x2006.main.CTFontScheme

    assertEquals(FontFamily.MODERN.getValue(),xssfFont.getFamily());
  }

  public void testScheme() {
    CTFont ctFont=CTFont.Factory.newInstance();
    CTFontScheme scheme=ctFont.addNewScheme();
    scheme.setVal(STFontScheme.MAJOR);
    ctFont.setSchemeArray(0,scheme);

    XSSFFont font=new XSSFFont(ctFont);
    assertEquals(FontScheme.MAJOR,font.getScheme());
View Full Code Here

Examples of org.openxmlformats.schemas.spreadsheetml.x2006.main.CTFontScheme

    // solo di xssfFont - non di Font-
    //sono utilizzati nel metodo createDefaultFont in StylesTable insta.

    public int getScheme(){
        CTFontScheme scheme=ctFont.sizeOfSchemeArray()==0?null:ctFont.getSchemeArray(0);
        if(scheme!=null){
            int fontScheme = scheme.getVal().intValue();
            switch (fontScheme) {
            case STFontScheme.INT_MAJOR:
                return XSSFFont.SCHEME_MAJOR;
            case STFontScheme.INT_MINOR:
                return XSSFFont.SCHEME_MINOR;
View Full Code Here

Examples of org.openxmlformats.schemas.spreadsheetml.x2006.main.CTFontScheme

        return 0;
    }


      public void setScheme(int scheme){
         CTFontScheme ctFontScheme=ctFont.sizeOfSchemeArray()==0?ctFont.addNewScheme():ctFont.getSchemeArray(0);
        switch (scheme) {
        case XSSFFont.SCHEME_MAJOR:
            ctFontScheme.setVal(STFontScheme.MAJOR);
            break;
        case XSSFFont.SCHEME_MINOR:
            ctFontScheme.setVal(STFontScheme.MINOR);
            break;
        case XSSFFont.SCHEME_NONE:
            ctFontScheme.setVal(STFontScheme.NONE);
            break;
        default:
            throw new RuntimeException("Schema value ["+ scheme +"] not supported in XSSFFont");
        }
    }
View Full Code Here

Examples of org.openxmlformats.schemas.spreadsheetml.x2006.main.CTFontScheme

  }


  public void testScheme(){
    CTFont ctFont=CTFont.Factory.newInstance();
    CTFontScheme scheme=ctFont.addNewScheme();
    scheme.setVal(STFontScheme.MAJOR);
    ctFont.setSchemeArray(0,scheme);

    XSSFFont font=new XSSFFont(ctFont);
    assertEquals(XSSFFont.SCHEME_MAJOR,font.getScheme());
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.