Package org.opentcs.guing.util
Class Colors
java.lang.Object
org.opentcs.guing.util.Colors
public class Colors
extends java.lang.Object
Utility methods concerning colors/colored elements.
-
Method Summary
Modifier and Type Method Description static java.util.List<java.awt.Color>defaultColors()static java.awt.ColorunusedBlockColor(java.util.List<org.opentcs.guing.model.elements.BlockModel> blocks)Returns a (preferredly unused) color for a new block.static java.awt.ColorunusedVehicleColor(java.util.List<org.opentcs.guing.model.elements.VehicleModel> vehicles)Returns a (preferredly unused) color for a new vehicle.
-
Method Details
-
defaultColors
public static final java.util.List<java.awt.Color> defaultColors() -
unusedBlockColor
public static java.awt.Color unusedBlockColor(java.util.List<org.opentcs.guing.model.elements.BlockModel> blocks)Returns a (preferredly unused) color for a new block.- Parameters:
blocks- The existing blocks.- Returns:
- The color to be used.
-
unusedVehicleColor
public static java.awt.Color unusedVehicleColor(java.util.List<org.opentcs.guing.model.elements.VehicleModel> vehicles)Returns a (preferredly unused) color for a new vehicle.- Parameters:
vehicles- The existing vehicles.- Returns:
- The color to be used.
-