tabbedpanetabbedpanetabpainter.java
来自「Mobile 应用程序使用 Java Micro Edition (Java M」· Java 代码 · 共 661 行 · 第 1/3 页
JAVA
661 行
path.closePath(); return path; }
private Paint decodeGradient1(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.5f,1.0f }, new Color[] { color1, decodeColor(color1,color2,0.5f), color2}); } private Paint decodeGradient2(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.1f,0.2f,0.6f,1.0f }, new Color[] { color3, decodeColor(color3,color4,0.5f), color4, decodeColor(color4,color5,0.5f), color5}); } private Paint decodeGradient3(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.5f,1.0f }, new Color[] { color6, decodeColor(color6,color2,0.5f), color2}); } private Paint decodeGradient4(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.1f,0.2f,0.6f,1.0f }, new Color[] { color7, decodeColor(color7,color8,0.5f), color8, decodeColor(color8,color9,0.5f), color9}); } private Paint decodeGradient5(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.5f,1.0f }, new Color[] { color10, decodeColor(color10,color2,0.5f), color2}); } private Paint decodeGradient6(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.1f,0.2f,0.42096776f,0.64193547f,0.82096773f,1.0f }, new Color[] { color11, decodeColor(color11,color12,0.5f), color12, decodeColor(color12,color13,0.5f), color13, decodeColor(color13,color14,0.5f), color14}); } private Paint decodeGradient7(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.5f,1.0f }, new Color[] { color15, decodeColor(color15,color16,0.5f), color16}); } private Paint decodeGradient8(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.1f,0.2f,0.6f,1.0f }, new Color[] { color17, decodeColor(color17,color18,0.5f), color18, decodeColor(color18,color5,0.5f), color5}); } private Paint decodeGradient9(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.12419355f,0.2483871f,0.42580646f,0.6032258f,0.6854839f,0.7677419f,0.88387096f,1.0f }, new Color[] { color19, decodeColor(color19,color20,0.5f), color20, decodeColor(color20,color21,0.5f), color21, decodeColor(color21,color22,0.5f), color22, decodeColor(color22,color23,0.5f), color23}); } private Paint decodeGradient10(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.5f,1.0f }, new Color[] { color24, decodeColor(color24,color2,0.5f), color2}); } private Paint decodeGradient11(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.5f,1.0f }, new Color[] { color25, decodeColor(color25,color2,0.5f), color2}); } private Paint decodeGradient12(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.12419355f,0.2483871f,0.42580646f,0.6032258f,0.6854839f,0.7677419f,0.86774194f,0.9677419f }, new Color[] { color26, decodeColor(color26,color27,0.5f), color27, decodeColor(color27,color28,0.5f), color28, decodeColor(color28,color29,0.5f), color29, decodeColor(color29,color30,0.5f), color30}); } private Paint decodeGradient13(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.5f,1.0f }, new Color[] { color25, decodeColor(color25,color31,0.5f), color31}); } private Paint decodeGradient14(Shape s) { Rectangle2D bounds = s.getBounds2D(); float x = (float)bounds.getX(); float y = (float)bounds.getY(); float w = (float)bounds.getWidth(); float h = (float)bounds.getHeight(); return decodeGradient((0.5f * w) + x, (0.0f * h) + y, (0.5f * w) + x, (1.0f * h) + y, new float[] { 0.0f,0.12419355f,0.2483871f,0.42580646f,0.6032258f,0.6854839f,0.7677419f,0.8548387f,0.9419355f }, new Color[] { color32, decodeColor(color32,color33,0.5f), color33, decodeColor(color33,color34,0.5f), color34, decodeColor(color34,color35,0.5f), color35, decodeColor(color35,color36,0.5f), color36}); }
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?