congrats Icon
New! Tabnine Pro 14-day free trial
Start a free trial
Tabnine Logo
GraphicUtils.filterColor
Code IndexAdd Tabnine to your IDE (free)

How to use
filterColor
method
in
org.mapsforge.core.graphics.GraphicUtils

Best Java code snippets using org.mapsforge.core.graphics.GraphicUtils.filterColor (Showing top 5 results out of 315)

origin: mapsforge/mapsforge

@Override
public void draw(Canvas canvas, Point origin, Matrix matrix, Filter filter) {
  Point adjustedStart = xy.offset(-origin.x, -origin.y);
  Point adjustedEnd = end.offset(-origin.x, -origin.y);
  if (this.paintBack != null) {
    int color = this.paintBack.getColor();
    if (filter != Filter.NONE) {
      this.paintBack.setColor(GraphicUtils.filterColor(color, filter));
    }
    canvas.drawTextRotated(text, (int) (adjustedStart.x),
        (int) (adjustedStart.y),
        (int) (adjustedEnd.x),
        (int) (adjustedEnd.y), this.paintBack);
    if (filter != Filter.NONE) {
      this.paintBack.setColor(color);
    }
  }
  int color = this.paintFront.getColor();
  if (filter != Filter.NONE) {
    this.paintFront.setColor(GraphicUtils.filterColor(color, filter));
  }
  canvas.drawTextRotated(text, (int) (adjustedStart.x),
      (int) (adjustedStart.y),
      (int) (adjustedEnd.x),
      (int) (adjustedEnd.y), this.paintFront);
  if (filter != Filter.NONE) {
    this.paintFront.setColor(color);
  }
}
origin: mapsforge/mapsforge

int colorF = this.paintFront.getColor();
if (filter != Filter.NONE) {
  this.paintFront.setColor(GraphicUtils.filterColor(colorF, filter));
    int colorB = this.paintBack.getColor();
    if (filter != Filter.NONE) {
      this.paintBack.setColor(GraphicUtils.filterColor(colorB, filter));
  int color = this.paintBack.getColor();
  if (filter != Filter.NONE) {
    this.paintBack.setColor(GraphicUtils.filterColor(color, filter));
  this.paintFront.setColor(GraphicUtils.filterColor(color, filter));
origin: mapsforge/mapsforge

int color = this.backLayout.getPaint().getColor();
if (filter != Filter.NONE) {
  this.backLayout.getPaint().setColor(GraphicUtils.filterColor(color, filter));
this.frontLayout.getPaint().setColor(GraphicUtils.filterColor(color, filter));
int color = this.paintBack.getColor();
if (filter != Filter.NONE) {
  this.paintBack.setColor(GraphicUtils.filterColor(color, filter));
this.paintFront.setColor(GraphicUtils.filterColor(color, filter));
origin: org.mapsforge/mapsforge-core

@Override
public void draw(Canvas canvas, Point origin, Matrix matrix, Filter filter) {
  Point adjustedStart = xy.offset(-origin.x, -origin.y);
  Point adjustedEnd = end.offset(-origin.x, -origin.y);
  if (this.paintBack != null) {
    int color = this.paintBack.getColor();
    if (filter != Filter.NONE) {
      this.paintBack.setColor(GraphicUtils.filterColor(color, filter));
    }
    canvas.drawTextRotated(text, (int) (adjustedStart.x),
        (int) (adjustedStart.y),
        (int) (adjustedEnd.x),
        (int) (adjustedEnd.y), this.paintBack);
    if (filter != Filter.NONE) {
      this.paintBack.setColor(color);
    }
  }
  int color = this.paintFront.getColor();
  if (filter != Filter.NONE) {
    this.paintFront.setColor(GraphicUtils.filterColor(color, filter));
  }
  canvas.drawTextRotated(text, (int) (adjustedStart.x),
      (int) (adjustedStart.y),
      (int) (adjustedEnd.x),
      (int) (adjustedEnd.y), this.paintFront);
  if (filter != Filter.NONE) {
    this.paintFront.setColor(color);
  }
}
origin: org.mapsforge/mapsforge-map-awt

int colorF = this.paintFront.getColor();
if (filter != Filter.NONE) {
  this.paintFront.setColor(GraphicUtils.filterColor(colorF, filter));
    int colorB = this.paintBack.getColor();
    if (filter != Filter.NONE) {
      this.paintBack.setColor(GraphicUtils.filterColor(colorB, filter));
  int color = this.paintBack.getColor();
  if (filter != Filter.NONE) {
    this.paintBack.setColor(GraphicUtils.filterColor(color, filter));
  this.paintFront.setColor(GraphicUtils.filterColor(color, filter));
org.mapsforge.core.graphicsGraphicUtilsfilterColor

Javadoc

Color filtering.

Popular methods of GraphicUtils

  • getAlpha
  • imageSize
    Given the original image size, as well as width, height, percent parameters, can compute the final i

Popular in Java

  • Making http post requests using okhttp
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • getSharedPreferences (Context)
  • requestLocationUpdates (LocationManager)
  • OutputStream (java.io)
    A writable sink for bytes.Most clients will use output streams that write data to the file system (
  • PrintWriter (java.io)
    Wraps either an existing OutputStream or an existing Writerand provides convenience methods for prin
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • Semaphore (java.util.concurrent)
    A counting semaphore. Conceptually, a semaphore maintains a set of permits. Each #acquire blocks if
  • Table (org.hibernate.mapping)
    A relational table
  • Scheduler (org.quartz)
    This is the main interface of a Quartz Scheduler. A Scheduler maintains a registry of org.quartz.Job
  • 14 Best Plugins for Eclipse
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyStudentsTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now