Static Public Member Functions | |
static bool | DoubleEqual (double a, double b) |
Returns true if the absolute difference between parameters is less than Epsilon. | |
static void | Swap (ref double a, ref double b) |
Swaps the value of two doubles. | |
static float | Distance (PointF a, PointF b) |
Calculate the distance between two points, a and b. | |
static int | Distance (Point a, Point b) |
Calculate the distance between two points, a and b. | |
static double | ToDouble (object o) |
Converts an object of type DateTime or IConvertible to double representation. | |
static bool | ArrayMinMax (IList a, out double min, out double max) |
Returns the minimum and maximum values in an IList. | |
static bool | RowArrayMinMax (DataRowCollection rows, out double min, out double max, string columnName) |
Returns the minimum and maximum values in a DataRowCollection. | |
static bool | DataViewArrayMinMax (DataView data, out double min, out double max, string columnName) |
Returns the minimum and maximum values in a DataView. | |
static PointF | UnitVector (PointF a, PointF b) |
Returns unit vector along the line a->b. | |
static Font | ScaleFont (Font initial, double scale) |
Get a Font exactly the same as the passed in one, except for scale factor. | |
static System.Drawing.Bitmap | TiledImage (System.Drawing.Bitmap image, Size size) |
Creates a bitmap from another that is tiled size times in each direction. | |
Public Attributes | |
const double | Epsilon = double.Epsilon * 1000.0 |
Numbers less than this are considered insignificant. |
Definition at line 63 of file Utils.cs.
|
Returns the minimum and maximum values in an IList. The members of the list can be of different types - any type for which the function Utils.ConvertToDouble knows how to convert into a double.
|
|
Returns the minimum and maximum values in a DataView.
|
|
Calculate the distance between two points, a and b.
|
|
Calculate the distance between two points, a and b.
|
|
Returns true if the absolute difference between parameters is less than Epsilon.
Definition at line 79 of file Utils.cs. References Epsilon. |
|
Returns the minimum and maximum values in a DataRowCollection.
|
|
Get a Font exactly the same as the passed in one, except for scale factor.
|
|
Swaps the value of two doubles.
|
|
Creates a bitmap from another that is tiled size times in each direction.
|
|
Converts an object of type DateTime or IConvertible to double representation. Mapping is 1:1. Note: the System.Convert.ToDouble method can not convert a boxed DateTime to double. This implementation can - but the "is" check probably makes it much slower. Compare speed with System.Convert.ToDouble and revise code that calls this if significant speed difference.
|
|
Returns unit vector along the line a->b.
|
|
Numbers less than this are considered insignificant. This number is bigger than double.Epsilon. Definition at line 70 of file Utils.cs. Referenced by DoubleEqual(). |