Package org.apache.fop.configuration

Examples of org.apache.fop.configuration.FontTriplet


                    fontInfo.addMetrics(internalName, font);
                   
                    Vector triplets = configFontInfo.getFontTriplets();
                    for (Enumeration t = triplets.elements();
                            t.hasMoreElements(); ) {
                        FontTriplet triplet = (FontTriplet)t.nextElement();

                        fontInfo.addFontProperties(internalName,
                                                   triplet.getName(),
                                                   triplet.getStyle(),
                                                   triplet.getWeight());
                    }
                }
            } catch (Exception ex) {
                MessageHandler.error("Failed to read font metrics file "
                                     + configFontInfo.getMetricsFile()
View Full Code Here


                                                 configFontInfo.getKerning());
                    fontInfo.addMetrics(internalName, font);

                    List triplets = configFontInfo.getFontTriplets();
                    for (int j = 0; j < triplets.size(); j++) {
                        FontTriplet triplet = (FontTriplet)triplets.get(j);

                        fontInfo.addFontProperties(internalName,
                                                   triplet.getName(),
                                                   triplet.getStyle(),
                                                   triplet.getWeight());
                    }
                }
            } catch (Exception ex) {
                MessageHandler.error("Failed to read a font metrics file: "
                                      + ex.getMessage());
View Full Code Here

                    internalName = "F" + num;
                    num++;

                    List triplets = configFontInfo.getFontTriplets();
                    for (int j = 0; j < triplets.size(); j++) {
                        FontTriplet triplet = (FontTriplet)triplets.get(j);
                        boolean embed = configFontInfo.getEmbedFile() != null;
                        // if embed font is not specified, use system "Dialog"
                        // logical font name for each Locale.
                        String family = embed ? triplet.getName() : "Dialog";
                        metric = new FontMetricsMapper(family,
                                                       getFontMetrics(triplet),
                                                       graphics);
                        if (embed)
                            metric.setEmbedFont(configFontInfo.getEmbedFile());
                        fontInfo.addMetrics(internalName, metric);
                        fontInfo.addFontProperties(internalName,
                                                   triplet.getName(),
                                                   triplet.getStyle(),
                                                   triplet.getWeight());
                    }
                }
            } catch (Exception ex) {
                MessageHandler.error("Failed to read font metrics file: "
                                     + ex.getMessage());
View Full Code Here

                reader.setFontEmbedPath(configFontInfo.getEmbedFile());
                fontInfo.addMetrics(internalName, reader.getFont());
               
                Vector triplets = configFontInfo.getFontTriplets();
                for (Enumeration t = triplets.elements(); t.hasMoreElements();) {
                    FontTriplet triplet = (FontTriplet)t.nextElement();
                   
                    fontInfo.addFontProperties(internalName,
                                               triplet.getName(),
                                               triplet.getStyle(),
                                               triplet.getWeight());
                }
            }
        } catch (Exception ex) {
            MessageHandler.error("Failed to read font metrics file " +
                                 configFontInfo.getMetricsFile() +
View Full Code Here

                    num++;
                   
                    Vector triplets = configFontInfo.getFontTriplets();
                    for (Enumeration t = triplets.elements();
                            t.hasMoreElements(); ) {
                        FontTriplet triplet = (FontTriplet)t.nextElement();
                        boolean embed = configFontInfo.getEmbedFile() != null;
                        // if embed font is not specified, use system "Dialog"
                        // logical font name for each Locale.
                        String family = embed ? triplet.getName() : "Dialog";
                        metric = new FontMetricsMapper(family,
                                                       getFontMetrics(triplet),
                                                       graphics);
                        if (embed)
                            metric.setEmbedFont(configFontInfo.getEmbedFile());
                        fontInfo.addMetrics(internalName, metric);
                        fontInfo.addFontProperties(internalName,
                                                   triplet.getName(),
                                                   triplet.getStyle(),
                                                   triplet.getWeight());
                    }
                }
            } catch (Exception ex) {
                MessageHandler.error("Failed to read font metrics file "
                                     + configFontInfo.getMetricsFile()
View Full Code Here

TOP

Related Classes of org.apache.fop.configuration.FontTriplet

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.