SWTGraphics.java 文件源码

java
阅读 35 收藏 0 点赞 0 评论 0

项目:gef-gwt 作者:
/**
 * Countermeasure against LineAttributes class not having a copy by value
 * function.
 * 
 * @since 3.6
 */
public static void copyLineAttributes(LineAttributes dest,
        LineAttributes src) {
    if (dest != src) {
        dest.cap = src.cap;
        dest.join = src.join;
        dest.miterLimit = src.miterLimit;
        dest.style = src.style;
        dest.width = src.width;
        dest.dashOffset = src.dashOffset;

        if (src.dash == null) {
            dest.dash = null;
        } else {
            if ((dest.dash == null)
                    || (dest.dash.length != src.dash.length)) {
                dest.dash = new float[src.dash.length];
            }
            System.arraycopy(src.dash, 0, dest.dash, 0, src.dash.length);
        }
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号