Android Context Get getLineErrorPaint(Context context)

Here you can find the source of getLineErrorPaint(Context context)

Description

get Line Error Paint

Declaration

public static Paint getLineErrorPaint(Context context) 

Method Source Code

//package com.java2s;

import android.content.Context;

import android.graphics.Paint;

import android.util.TypedValue;

public class Main {
    public static final int DEFAULT_LINE_THICKNESS = 5;
    public static final int DEFAULT_LINE_ERROR_COLOR = 0x4500CCEE;

    public static Paint getLineErrorPaint(Context context) {
        final float lineThicknessPx = TypedValue.applyDimension(
                TypedValue.COMPLEX_UNIT_DIP, DEFAULT_LINE_THICKNESS,
                context.getResources().getDisplayMetrics());

        final Paint borderPaint = new Paint();
        borderPaint.setColor(DEFAULT_LINE_ERROR_COLOR);
        borderPaint.setStrokeWidth(lineThicknessPx);
        borderPaint.setStyle(Paint.Style.STROKE);
        borderPaint.setAntiAlias(true);//from ww  w .ja  v  a2s.  co m
        return borderPaint;
    }
}

Related

  1. getImei(Context context, String imei)
  2. getInstalleApps(Context mContext)
  3. getInstance(Context context)
  4. getIntSPR(String key, Context context)
  5. getLastKnownLocation(Context context)
  6. getLinePaint(Context context)
  7. getLineThickness(Context context)
  8. getLocationProvider(Context context)
  9. getLongSPR(String key, Context context)