Tabnine Logo
PolygonOptions.strokeColor
Code IndexAdd Tabnine to your IDE (free)

How to use
strokeColor
method
in
com.google.android.gms.maps.model.PolygonOptions

Best Java code snippets using com.google.android.gms.maps.model.PolygonOptions.strokeColor (Showing top 20 results out of 315)

origin: airbnb/AirMapView

public Builder<T> strokeColor(int color) {
 polygonOptions.strokeColor(color);
 return this;
}
origin: googlemaps/android-maps-utils

/**
 * Sets the stroke color of the GeoJsonPolygon as a 32-bit ARGB color
 *
 * @param strokeColor stroke color value of the GeoJsonPolygon
 */
public void setStrokeColor(int strokeColor) {
  mPolygonOptions.strokeColor(strokeColor);
  styleChanged();
}
origin: airbnb/AirMapView

public Builder() {
 polygonOptions.strokeWidth(STROKE_WIDTH);
 polygonOptions.strokeColor(STROKE_COLOR);
}
origin: googlemaps/android-maps-utils

/**
 * Sets the outline color for a Polyline and a Polygon using a String
 *
 * @param color Outline color for a Polyline and a Polygon represented as a String
 */
/* package */ void setOutlineColor(String color) {
  // Add # to allow for mOutline color to be parsed correctly
  mPolylineOptions.color(Color.parseColor("#" + convertColor(color)));
  mPolygonOptions.strokeColor(Color.parseColor("#" + convertColor(color)));
  mStylesSet.add("outlineColor");
}
origin: googlemaps/android-maps-utils

/**
 *Creates a new PolygonOption from given properties of an existing PolygonOption
 * @param originalPolygonOption An existing PolygonOption instance
 * @param isFill Whether the fill for a polygon is set
 * @param isOutline Whether the outline for a polygon is set
 * @return  A new PolygonOption
 */
private static PolygonOptions createPolygonOptions (PolygonOptions originalPolygonOption,
    boolean isFill, boolean isOutline) {
  PolygonOptions polygonOptions = new PolygonOptions();
  if (isFill) {
    polygonOptions.fillColor(originalPolygonOption.getFillColor());
  }
  if (isOutline) {
    polygonOptions.strokeColor(originalPolygonOption.getStrokeColor());
    polygonOptions.strokeWidth(originalPolygonOption.getStrokeWidth());
  }
  return polygonOptions;
}
origin: googlemaps/android-maps-utils

/**
 * Gets a new PolygonOptions object containing styles for the GeoJsonPolygon
 *
 * @return new PolygonOptions object
 */
public PolygonOptions toPolygonOptions() {
  PolygonOptions polygonOptions = new PolygonOptions();
  polygonOptions.fillColor(mPolygonOptions.getFillColor());
  polygonOptions.geodesic(mPolygonOptions.isGeodesic());
  polygonOptions.strokeColor(mPolygonOptions.getStrokeColor());
  polygonOptions.strokeWidth(mPolygonOptions.getStrokeWidth());
  polygonOptions.visible(mPolygonOptions.isVisible());
  polygonOptions.zIndex(mPolygonOptions.getZIndex());
  polygonOptions.clickable(mPolygonOptions.isClickable());
  return polygonOptions;
}
origin: googlemaps/android-maps-utils

.addAll(triangle)
.fillColor(Color.BLUE - ALPHA_ADJUSTMENT)
.strokeColor(Color.BLUE)
.strokeWidth(5));
.addAll(simplifiedTriangle)
.fillColor(Color.YELLOW - ALPHA_ADJUSTMENT)
.strokeColor(Color.YELLOW)
.strokeWidth(5));
.addAll(oval)
.fillColor(Color.BLUE - ALPHA_ADJUSTMENT)
.strokeColor(Color.BLUE)
.strokeWidth(5));
.addAll(simplifiedOval)
.fillColor(Color.YELLOW - ALPHA_ADJUSTMENT)
.strokeColor(Color.YELLOW)
.strokeWidth(5));
origin: googlemaps/android-maps-utils

/**
 * Sets the inline polygon style by copying over the styles that have been set
 *
 * @param polygonOptions polygon options object to add inline styles to
 * @param inlineStyle    inline styles to apply
 */
private void setInlinePolygonStyle(PolygonOptions polygonOptions, KmlStyle inlineStyle) {
  PolygonOptions inlinePolygonOptions = inlineStyle.getPolygonOptions();
  if (inlineStyle.hasFill() && inlineStyle.isStyleSet("fillColor")) {
    polygonOptions.fillColor(inlinePolygonOptions.getFillColor());
  }
  if (inlineStyle.hasOutline()) {
    if (inlineStyle.isStyleSet("outlineColor")) {
      polygonOptions.strokeColor(inlinePolygonOptions.getStrokeColor());
    }
    if (inlineStyle.isStyleSet("width")) {
      polygonOptions.strokeWidth(inlinePolygonOptions.getStrokeWidth());
    }
  }
  if (inlineStyle.isPolyRandomColorMode()) {
    polygonOptions.fillColor(KmlStyle.computeRandomColor(inlinePolygonOptions.getFillColor()));
  }
}
origin: commonsguy/cw-omnibus

   new LatLng(40.758393, -73.992705),
   new LatLng(40.753484, -73.980882))
.strokeColor(Color.BLUE);
origin: googlemaps/android-samples

.addHole(createRectangle(new LatLng(-18, 133), 0.5, 1.5))
.fillColor(fillColorArgb)
.strokeColor(strokeColorArgb)
.strokeWidth(mStrokeWidthBar.getProgress())
.clickable(mClickabilityCheckbox.isChecked()));
origin: mg6maciej/android-maps-extensions

public PolygonOptions strokeColor(int color) {
  real.strokeColor(color);
  return this;
}
origin: googlemaps/android-samples

/**
 * Add a Polyline and a Polygon to the map.
 * The Polyline connects Melbourne, Adelaide and Perth. The Polygon is located in the Northern
 * Territory (Australia).
 */
private void addPolyObjects() {
  mMap.addPolyline((new PolylineOptions())
      .add(MELBOURNE, ADELAIDE, PERTH)
      .color(Color.GREEN)
      .width(5f));
  mMap.addPolygon(new PolygonOptions()
      .add(POLYGON)
      .fillColor(Color.CYAN)
      .strokeColor(Color.BLUE)
      .strokeWidth(5));
}
origin: googlemaps/android-samples

        new LatLng(DARWIN.latitude - 3, DARWIN.longitude - 3))
    .fillColor(Color.argb(150, 34, 173, 24))
    .strokeColor(Color.rgb(34, 173, 24))
    .clickable(true));
mDarwinPolygon.setTag(new CustomTag("Darwin polygon"));
origin: wiglenet/wigle-wifi-wardriving

/**
 * Sets the stroke color of the GeoJsonPolygon as a 32-bit ARGB color
 *
 * @param strokeColor stroke color value of the GeoJsonPolygon
 */
public void setStrokeColor(int strokeColor) {
  mPolygonOptions.strokeColor(strokeColor);
  styleChanged();
}
origin: wiglenet/wigle-wifi-wardriving

/**
 * Sets the outline color for a Polyline and a Polygon
 *
 * @param color Outline color for a Polyline and a Polygon
 */
/* package */ void setOutlineColor(String color) {
  // Add # to allow for mOutline color to be parsed correctly
  mPolylineOptions.color(Color.parseColor("#" + convertColor(color)));
  mPolygonOptions.strokeColor(Color.parseColor("#" + color));
  mStylesSet.add("outlineColor");
}
origin: wiglenet/wigle-wifi-wardriving

/**
 *Creates a new PolygonOption from given properties of an existing PolygonOption
 * @param originalPolygonOption An existing PolygonOption instance
 * @param isFill Whether the fill for a polygon is set
 * @param isOutline Whether the outline for a polygon is set
 * @return  A new PolygonOption
 */
private static PolygonOptions createPolygonOptions (PolygonOptions originalPolygonOption,
    boolean isFill, boolean isOutline) {
  PolygonOptions polygonOptions = new PolygonOptions();
  if (isFill) {
    polygonOptions.fillColor(originalPolygonOption.getFillColor());
  }
  if (isOutline) {
    polygonOptions.strokeColor(originalPolygonOption.getStrokeColor());
    polygonOptions.strokeWidth(originalPolygonOption.getStrokeWidth());
  }
  return polygonOptions;
}
origin: bkhezry/MapDrawingTools

private void drawPolygon(List<LatLng> latLngList) {
 if (polygon != null) {
  polygon.remove();
 }
 PolygonOptions polygonOptions = new PolygonOptions();
 polygonOptions.fillColor(drawingOption.getFillColor());
 polygonOptions.strokeColor(drawingOption.getStrokeColor());
 polygonOptions.strokeWidth(drawingOption.getStrokeWidth());
 polygonOptions.addAll(latLngList);
 polygon = mMap.addPolygon(polygonOptions);
}
origin: car2go/AnyMaps

@Override
public com.google.android.gms.maps.model.PolygonOptions map(PolygonOptions input) {
  List<LatLng> points = AnyMapAdapter.adaptList(com.car2go.maps.model.LatLng.class, input.getPoints());
  return new com.google.android.gms.maps.model.PolygonOptions()
      .fillColor(input.getFillColor())
      .strokeColor(input.getStrokeColor())
      .strokeWidth(input.getStrokeWidth())
      .addAll(points);
}
origin: livroandroid/5ed

  protected void testePolygon(GoogleMap map) {
    PolygonOptions p = new PolygonOptions();
    p.add(new LatLng(-23.564391, -46.651717));
    p.add(new LatLng(-23.565391, -46.652717));
    p.add(new LatLng(-23.564282, -46.654337));
    p.add(new LatLng(-23.563114, -46.653283));
//        p.add(new LatLng(-23.564391, -46.651717));
    p.strokeColor(Color.GREEN);
    p.fillColor(Color.RED);
    Polygon polygon = map.addPolygon(p);
    polygon.setFillColor(Color.YELLOW);
  }

origin: wiglenet/wigle-wifi-wardriving

/**
 * Gets a new PolygonOptions object containing styles for the GeoJsonPolygon
 *
 * @return new PolygonOptions object
 */
public PolygonOptions toPolygonOptions() {
  PolygonOptions polygonOptions = new PolygonOptions();
  polygonOptions.fillColor(mPolygonOptions.getFillColor());
  polygonOptions.geodesic(mPolygonOptions.isGeodesic());
  polygonOptions.strokeColor(mPolygonOptions.getStrokeColor());
  polygonOptions.strokeWidth(mPolygonOptions.getStrokeWidth());
  polygonOptions.visible(mPolygonOptions.isVisible());
  polygonOptions.zIndex(mPolygonOptions.getZIndex());
  return polygonOptions;
}
com.google.android.gms.maps.modelPolygonOptionsstrokeColor

Popular methods of PolygonOptions

  • fillColor
  • <init>
  • strokeWidth
  • addAll
  • add
  • getFillColor
  • getStrokeColor
  • getStrokeWidth
  • addHole
  • zIndex
  • geodesic
  • getZIndex
  • geodesic,
  • getZIndex,
  • isGeodesic,
  • isVisible,
  • visible,
  • clickable,
  • getPoints,
  • isClickable,
  • strokePattern

Popular in Java

  • Running tasks concurrently on multiple threads
  • setRequestProperty (URLConnection)
  • setContentView (Activity)
  • getExternalFilesDir (Context)
  • Socket (java.net)
    Provides a client-side TCP socket.
  • Random (java.util)
    This class provides methods that return pseudo-random values.It is dangerous to seed Random with the
  • StringTokenizer (java.util)
    Breaks a string into tokens; new code should probably use String#split.> // Legacy code: StringTo
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • TimeUnit (java.util.concurrent)
    A TimeUnit represents time durations at a given unit of granularity and provides utility methods to
  • JFrame (javax.swing)
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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