亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? omtext.java

?? openmap java寫的開源數字地圖程序. 用applet實現,可以像google map 那樣放大縮小地圖.
?? JAVA
?? 第 1 頁 / 共 3 頁
字號:
// **********************************************************************// // <copyright>// //  BBN Technologies//  10 Moulton Street//  Cambridge, MA 02138//  (617) 873-8000// //  Copyright (C) BBNT Solutions LLC. All rights reserved.// // </copyright>// **********************************************************************// // $Source: /cvs/distapps/openmap/src/openmap/com/bbn/openmap/omGraphics/OMText.java,v $// $RCSfile: OMText.java,v $// $Revision: 1.11.2.6 $// $Date: 2006/01/27 15:20:56 $// $Author: dietrick $// // **********************************************************************package com.bbn.openmap.omGraphics;import java.awt.BasicStroke;import java.awt.Color;import java.awt.Font;import java.awt.FontMetrics;import java.awt.Graphics;import java.awt.Graphics2D;import java.awt.Point;import java.awt.Polygon;import java.awt.Rectangle;import java.awt.Shape;import java.awt.Stroke;import java.awt.font.FontRenderContext;import java.awt.font.GlyphVector;import java.awt.geom.AffineTransform;import java.awt.geom.GeneralPath;import java.awt.geom.PathIterator;import java.io.IOException;import java.io.ObjectInputStream;import java.io.ObjectOutputStream;import java.io.Serializable;import com.bbn.openmap.proj.Projection;import com.bbn.openmap.util.Debug;/** * The OMText graphic type lets you put text on the screen. The location of the * string is really the location of the lower left corner of the first letter of * the string. */public class OMText extends OMGraphic implements Serializable {    // ----------------------------------------------------------------------    // Static constants    // ----------------------------------------------------------------------    /** Align the text to the right of the location. */    public final static transient int JUSTIFY_LEFT = 0;    /** Align the text centered on the location. */    public final static transient int JUSTIFY_CENTER = 1;    /** Align the text to the left of the location. */    public final static transient int JUSTIFY_RIGHT = 2;    /**     * Parameter of Font to count toward footprint of height of Text. This     * indicates that the ascent, descent and leading of the text should count     * toward the footprint of the text. This is the same as the full height of     * the FontMetric, and is the default.     */    public final static transient int HEIGHT = 0;    /**     * Parameter of Font to count toward footprint of height of Text. This     * indicates that the ascent and the descent of the text should count toward     * the footprint of the text.     */    public final static transient int ASCENT_DESCENT = 1;    /**     * Parameter of Font to count toward footprint of height of Text. This     * indicates that the ascent and the leading of the text should count toward     * the footprint of the text.     */    public final static transient int ASCENT_LEADING = 2;    /**     * Parameter of Font to count toward footprint of height of Text. This     * indicates that just the ascent of the text should count toward the     * footprint of the text.     */    public final static transient int ASCENT = 3;    /**     * Parameter that dictates where the font baseline will be set compared to     * the location of the OMText. The BASELINE_BOTTOM setting, the default,     * means that the location will be set along the normal bottom edge of the     * text where the letters rest.     */    public final static transient int BASELINE_BOTTOM = 0;    /**     * Parameter that dictates where the font baseline will be set compared to     * the location of the OMText. The BASELINE_MIDDLE setting means that the     * location will be set along the middle of the height of the text.     */    public final static transient int BASELINE_MIDDLE = 1;    /**     * Parameter that dictates where the font baseline will be set compared to     * the location of the OMText. The BASELINE_TOP setting means that the     * location will be set along the top of the height of the text.     */    public final static transient int BASELINE_TOP = 2;    public static final Font DEFAULT_FONT = new Font("SansSerif", java.awt.Font.PLAIN, 12);    /**     * The default text matte stroke that is used to surround each character     * with the color set in the textMatteColor attribute.     */    public static final Stroke DEFAULT_TEXT_MATTE_STROKE = new BasicStroke(2f);    // ----------------------------------------------------------------------    // Fields    // ----------------------------------------------------------------------    /**     * The projected xy window location of the bottom left corner of the first     * letter of the text string.     */    protected Point pt;    /** The X/Y point or the offset amount depending on render type. */    protected Point point;    /** The Font type that the string should be displayed with. */    protected Font f;    /**     * The FontSizer set in the OMText, changing the font size appropriate for a     * projection scale.     */    protected FontSizer fontSizer = null;    /**     * The latitude location for the text, used for lat/lon or offset rendertype     * texts, in decimal degrees.     */    protected float lat = 0.0f;    /**     * The longitude location for the text, used for lat/lon or offset     * rendertype texts, in decimal degrees.     */    protected float lon = 0.0f;    /** The string to be displayed. */    protected String data = null;    /**     * Justification of the string. Will let you put the text to the right,     * centered or to the left of the given location.     */    protected int justify = JUSTIFY_LEFT;    /**     * Location of the baseline of the text compared to the location point of     * the OMText object. You can set this to be BASELINE_BOTTOM (default),     * BASELINE_MIDDLE or BASELINE_TOP, depending on if you want the bottom of     * the letters to be lined up to the location, or the middle or the top of     * them.     */    protected int baseline = BASELINE_BOTTOM;    /**     * The fmHeight is the FontMetric height to use for calculating the     * footprint for the line. This becomes important for multi-line text and     * text in decluttering, because it dictates the amount of space surrounding     * the text. The default height is to take into account the ascent, descent     * and leading of the font.     */    protected int fmHeight = HEIGHT;    protected boolean useMaxWidthForBounds = false;    /** The angle by which the text is to be rotated, in radians */    protected double rotationAngle = DEFAULT_ROTATIONANGLE;    /**     * The text matte color surrounds each character of the string with this     * color. If the color is null, the text matte is not used.     */    protected Color textMatteColor;    /**     * The stroke used to paint the outline of each character. The stroke should     * be larger than 1 to give proper effect.     */    protected Stroke textMatteStroke = DEFAULT_TEXT_MATTE_STROKE;    // ----------------------------------------------------------------------    // Caches    // These fields cache computed data.    // ----------------------------------------------------------------------    /** The bounding rectangle of this Text. */    protected transient Polygon polyBounds;    /** The Metrics of the current font. */    protected transient FontMetrics fm;    /** The text split by newlines. */    protected transient String parsedData[];    /** cached string widths. */    protected transient int widths[];    // ----------------------------------------------------------------------    // Constructors    // ----------------------------------------------------------------------    /**     * Default constructor. Produces an instance with no location and an empty     * string for text. For this instance to be useful it needs text (setData),     * a location (setX, setY, setLat, setLon) and a renderType (setRenderType).     */    public OMText() {        super(RENDERTYPE_UNKNOWN, LINETYPE_UNKNOWN, DECLUTTERTYPE_NONE);        point = new Point(0, 0);        setData("");        f = DEFAULT_FONT;    }    /**     * Creates a text object, with Lat/Lon placement, and default SansSerif     * font.     *      * @param lt latitude of the string, in decimal degrees.     * @param ln longitude of the string, in decimal degrees.     * @param stuff the string to be displayed.     * @param just the justification of the string     */    public OMText(float lt, float ln, String stuff, int just) {        this(lt, ln, stuff, DEFAULT_FONT, just);    }    /**     * Creates a text object, with Lat/Lon placement.     *      * @param lt latitude of the string, in decimal degrees.     * @param ln longitude of the string, in decimal degrees.     * @param stuff the string to be displayed.     * @param font the Font description for the string.     * @param just the justification of the string     */    public OMText(float lt, float ln, String stuff, Font font, int just) {        super(RENDERTYPE_LATLON, LINETYPE_UNKNOWN, DECLUTTERTYPE_NONE);        lat = lt;        lon = ln;        setData(stuff);        f = font;        justify = just;    }    /**     * Creates a text object, with XY placement, and default SansSerif font.     *      * @param px1 horizontal window pixel location of the string.     * @param py1 vertical window pixel location of the string.     * @param stuff the string to be displayed.     * @param just the justification of the string     */    public OMText(int px1, int py1, String stuff, int just) {        this(px1, py1, stuff, DEFAULT_FONT, just);    }    /**     * Creates a text object, with XY placement.     *      * @param px1 horizontal window pixel location of the string.     * @param py1 vertical window pixel location of the string.     * @param stuff the string to be displayed.     * @param font the Font description for the string.     * @param just the justification of the string     */    public OMText(int px1, int py1, String stuff, Font font, int just) {        super(RENDERTYPE_XY, LINETYPE_UNKNOWN, DECLUTTERTYPE_NONE);        point = new Point(px1, py1);        setData(stuff);        f = font;        justify = just;    }    /**     * Creates a Text object, with lat/lon placement with XY offset, and default     * SansSerif font.     *      * @param lt latitude of the string, in decimal degrees.     * @param ln longitude of the string, in decimal degrees.     * @param offX horizontal offset of string     * @param offY vertical offset of string     * @param aString the string to be displayed.     * @param just the justification of the string     */    public OMText(float lt, float ln, int offX, int offY, String aString,            int just) {        this(lt, ln, offX, offY, aString, DEFAULT_FONT, just);    }    /**     * Creates a Text object, with lat/lon placement with XY offset.     *      * @param lt latitude of the string, in decimal degrees.     * @param ln longitude of the string, in decimal degrees.     * @param offX horizontal offset of string     * @param offY vertical offset of string     * @param aString the string to be displayed.     * @param font the Font description for the string.     * @param just the justification of the string     */    public OMText(float lt, float ln, int offX, int offY, String aString,            Font font, int just) {        super(RENDERTYPE_OFFSET, LINETYPE_UNKNOWN, DECLUTTERTYPE_NONE);        lat = lt;        lon = ln;        point = new Point(offX, offY);        setData(aString);        f = font;        justify = just;    }    /**     * Get the font of the text object, which might have been scaled by the font     * sizer.     *      * @return the font of the object.     */    public Font getFont() {        if (f == null) {            f = DEFAULT_FONT;        }        return f;    }    /**     * Set the base font. Will take effect on the next render. If the font sizer     * is not null, this font will be set in that object as well, and the active     * font will come from the font sizer. To make the set font the constant     * font, set the font sizer to null. Flushes the cache fields     * <code>fm</code>, <code>widths</code>, and <code>polyBounds</code>.     * Calls setScaledFont.     *      * @param aFont font to be used for the text.     *      * @see #fm     * @see #widths     * @see #polyBounds     */    public void setFont(Font aFont) {        if (fontSizer != null) {            fontSizer.setFont(aFont);            setScaledFont(fontSizer.getScaledFont());        } else {            setScaledFont(aFont);        }    }    /**     * Sets the scaled font, which is the one that is used for rendering.     */    protected void setScaledFont(Font aFont) {        f = aFont;        // now flush the cached information about the old font        fm = null; // flush existing metrics.        widths = null; // flush existing width table.        polyBounds = null; // flush existing bounds.    }    /**     * If the font sizer is not null, sets the scaled font with the proper value     * for the given scale.     */    public void setFont(float scale) {        if (fontSizer != null) {            setScaledFont(fontSizer.getFont(scale));        }    }    /**     * Set the FontSizer object, which provides different font sizes at     * different scales. If set to null, the font size will remain constant     * regardless of projection scale.     */    public void setFontSizer(FontSizer fs) {        Font bf = getFont();        if (fontSizer != null) {            bf = fontSizer.getFont();        }        fontSizer = fs;        setFont(bf);    }    /**     * Get the FontSizer object, which provides different font sizes at     * different scales. If set to null, the font size will remain constant     * regardless of projection scale.     */    public FontSizer getFontSizer() {        return fontSizer;    }    /**     * Get the x location. Applies to XY and OFFSET text objects.     *      * @return the horizontal window location of the string, from the left of     *         the window.     */    public int getX() {        if (point != null) {            return point.x;        } else {            return 0;        }    }    /**     * Set the x location. Applies to XY and OFFSET text objects.     *      * @param newX the horizontal pixel location of the window to place the     *        string.     */    public void setX(int newX) {        if (point == null && getRenderType() == RENDERTYPE_LATLON) {            point = new Point();            setRenderType(RENDERTYPE_OFFSET);        }        point.x = newX;        setNeedToRegenerate(true);    }    /**     * Get the y location. Applies to XY and OFFSET text objects.     *      * @return the vertical pixel location of the string, from the top of the     *         window.     */    public int getY() {        if (point != null) {            return point.y;        } else {            return 0;        }    }    /**

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产在线精品免费| 国产婷婷色一区二区三区在线| 91精品国产免费久久综合| 日韩一区二区三区观看| 国产日韩精品一区二区三区| 亚洲欧洲色图综合| 男女男精品视频网| 99re成人精品视频| 91精品国产一区二区| 国产视频视频一区| 亚洲成人福利片| 国产精品综合久久| 欧美午夜宅男影院| 国产日韩欧美精品电影三级在线 | 精品一二三四在线| 91丝袜高跟美女视频| 欧美一级在线免费| 日韩理论片中文av| 韩国欧美国产1区| 91久久线看在观草草青青| 精品成人在线观看| 亚洲自拍偷拍av| 国产999精品久久久久久绿帽| 欧美日韩免费观看一区二区三区 | 国产一区999| 欧日韩精品视频| 国产女人aaa级久久久级| 天天影视网天天综合色在线播放| 国产成人精品综合在线观看| 51精品视频一区二区三区| 成人免费视频在线观看| 黄色精品一二区| 欧美人xxxx| 亚洲男同1069视频| 国产a久久麻豆| 精品免费日韩av| 五月婷婷另类国产| 91蝌蚪porny| 国产欧美日韩在线看| 免费久久99精品国产| 在线免费观看日韩欧美| 国产精品少妇自拍| 国产原创一区二区三区| 日韩三级精品电影久久久 | 欧美高清视频一二三区| 亚洲日本护士毛茸茸| 国产成人精品免费在线| 欧美v日韩v国产v| 日韩精品电影在线| 欧美日韩精品一区视频| 亚洲激情第一区| 91亚洲精品乱码久久久久久蜜桃| 国产欧美日本一区视频| 国产精品一区专区| 久久中文娱乐网| 精品一区二区三区免费视频| 日韩精品资源二区在线| 日韩电影在线免费| 欧美精品1区2区| 日韩在线卡一卡二| 欧美一区二区三区免费观看视频| 亚洲高清免费观看高清完整版在线观看| 91免费视频网址| 最近日韩中文字幕| 91免费版在线看| 最新欧美精品一区二区三区| av综合在线播放| 亚洲欧美日韩成人高清在线一区| 本田岬高潮一区二区三区| 中文av一区特黄| 成人动漫精品一区二区| 国产精品国产a| 99久久精品国产毛片| 亚洲日本在线看| 欧美自拍偷拍一区| 亚洲3atv精品一区二区三区| 欧美日韩黄视频| 蜜臀久久99精品久久久久宅男| 日韩欧美一区在线| 国产一区视频导航| 中文字幕精品在线不卡| 成人h动漫精品一区二| 国产精品不卡视频| 欧洲亚洲国产日韩| 日韩精品国产精品| 2欧美一区二区三区在线观看视频| 国产jizzjizz一区二区| 中文字幕一区二区三区不卡在线 | 亚洲精选视频免费看| 在线观看日韩高清av| 亚洲一级二级三级在线免费观看| 欧美久久久久久久久中文字幕| 奇米影视在线99精品| 久久免费偷拍视频| 99久久精品国产麻豆演员表| 亚洲国产成人高清精品| 欧美va在线播放| 成人av电影在线观看| 亚洲第一av色| www激情久久| 成人黄色综合网站| 亚洲一区二区不卡免费| 欧美成人一区二区三区| 成人性色生活片| 亚洲无线码一区二区三区| 欧美xxxxx裸体时装秀| av成人动漫在线观看| 日韩成人av影视| 国产农村妇女精品| 欧美视频中文一区二区三区在线观看| 免费观看日韩电影| 1024国产精品| 5566中文字幕一区二区电影| 粉嫩一区二区三区性色av| 一区二区三区丝袜| 精品久久免费看| 91麻豆视频网站| 美脚の诱脚舐め脚责91| 综合色中文字幕| 日韩精品一区二区三区四区| 99久久婷婷国产| 精品一区中文字幕| 亚洲精品免费播放| 337p粉嫩大胆噜噜噜噜噜91av| 色综合色综合色综合色综合色综合 | 国产乱一区二区| 一区二区三区 在线观看视频| 717成人午夜免费福利电影| 成人激情小说网站| 久久精品国产一区二区三 | 欧美日韩的一区二区| 国产乱理伦片在线观看夜一区| 亚洲一区二区精品视频| 欧美经典三级视频一区二区三区| 欧美视频精品在线| 波多野结衣精品在线| 久久国产免费看| 亚洲第一搞黄网站| 亚洲人精品午夜| 精品成人a区在线观看| 欧洲精品中文字幕| 99精品桃花视频在线观看| 狠狠色综合色综合网络| 三级不卡在线观看| 亚洲色欲色欲www在线观看| 亚洲精品一区二区三区蜜桃下载| 欧美无砖专区一中文字| 91网站在线播放| 国产精品538一区二区在线| 全国精品久久少妇| 亚洲一区二区在线观看视频| 国产欧美精品国产国产专区 | 福利一区二区在线| 久久精品国产秦先生| 亚洲成a人v欧美综合天堂下载| ...av二区三区久久精品| 国产欧美一区二区精品仙草咪| 日韩亚洲欧美一区二区三区| 欧美日韩国产美| 欧美特级限制片免费在线观看| 成人午夜私人影院| 国产一区二区三区在线观看免费视频 | 成人av网站在线观看| 经典一区二区三区| 蜜臀av国产精品久久久久| 亚洲国产欧美另类丝袜| 亚洲黄色小说网站| 亚洲私人黄色宅男| 国产精品美女久久久久久久久久久 | 午夜精品久久久久影视| 一区二区三区在线播放| 亚洲视频免费在线观看| 成人免费在线视频观看| 国产精品国产三级国产aⅴ原创 | 色94色欧美sute亚洲13| aaa欧美日韩| av不卡免费在线观看| 99在线精品一区二区三区| 国产高清成人在线| 国产超碰在线一区| 大胆欧美人体老妇| av在线不卡免费看| 91色婷婷久久久久合中文| 91色在线porny| 在线观看日韩国产| 欧美日韩激情在线| 日韩午夜精品电影| 日韩欧美精品三级| 久久亚洲捆绑美女| 久久免费的精品国产v∧| 久久久久综合网| 国产精品卡一卡二| 亚洲伦理在线精品| 亚洲国产日韩在线一区模特| 亚洲国产视频a| 看电影不卡的网站| 国产成人综合自拍| 色综合久久综合| 欧美日韩中文另类| 日韩欧美一区二区三区在线|