/** Get a texture from a WMF hatch definition, with a foreground color. This * texture will be cached, so the Paint will only be created once. */ public Paint getTexture(int textureId, Color foreground) { ColoredTexture _ctexture = new ColoredTexture(textureId, foreground, null); if (textures.containsKey(_ctexture)) { Paint paint = (Paint)(textures.get(_ctexture)); return paint; } else { Paint paint = createTexture(textureId, foreground, null); if (paint != null) textures.put(_ctexture, paint); return paint; } }
/** Get a texture from a WMF hatch definition, with a foreground color. This * texture will be cached, so the Paint will only be created once. */ public Paint getTexture(int textureId, Color foreground) { ColoredTexture _ctexture = new ColoredTexture(textureId, foreground, null); if (textures.containsKey(_ctexture)) { Paint paint = (Paint)(textures.get(_ctexture)); return paint; } else { Paint paint = createTexture(textureId, foreground, null); if (paint != null) textures.put(_ctexture, paint); return paint; } }
/** Get a texture from a WMF hatch definition, with a foreground and a * background color. This texture will be cached, so the Paint will * only be created once. */ public Paint getTexture(int textureId, Color foreground, Color background) { ColoredTexture _ctexture = new ColoredTexture(textureId, foreground, background); if (textures.containsKey(_ctexture)) { Paint paint = (Paint)(textures.get(_ctexture)); return paint; } else { Paint paint = createTexture(textureId, foreground, background); if (paint != null) textures.put(_ctexture, paint); return paint; } }
/** Get a texture from a WMF hatch definition, with a foreground and a * background color. This texture will be cached, so the Paint will * only be created once. */ public Paint getTexture(int textureId, Color foreground, Color background) { ColoredTexture _ctexture = new ColoredTexture(textureId, foreground, background); if (textures.containsKey(_ctexture)) { Paint paint = (Paint)(textures.get(_ctexture)); return paint; } else { Paint paint = createTexture(textureId, foreground, background); if (paint != null) textures.put(_ctexture, paint); return paint; } }