Package io.keikai.ui.impl
Class XUtils
- java.lang.Object
-
- io.keikai.ui.impl.XUtils
-
public class XUtils extends Object
-
-
Constructor Summary
Constructors Constructor Description XUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
defaultColumnWidthToPx(int columnWidth, int charWidth)
Convert default columns character width to pixelstatic int
fileChar256ToPx(int char256, int charWidth)
convert file 1/256 character width to pixelstatic double
getDoubleVersion()
static boolean
isTitleIndexMode(Spreadsheet ss)
Returns whether theSpreadsheet
title is in index modestatic String
nextUpdateId()
static int
pointToPx(int point)
convert point to pixelstatic int
pointToTwip(int px)
convert point to twip (1/20 point)static int
pxToFileChar256(int px, int charWidth)
convert pixel to file 1/256 character widthstatic int
pxToPoint(int px)
convert pixel to pointstatic double
pxToScreenChar1(int px, int charWidth)
Convert pixel to character width (for application)static int
pxToScreenChar256(int px, int charWidth)
Convert pixel to 1/256 character widthstatic int
pxToTwip(int px)
convert pixel to twip (1/20 point)static int
screenChar1ToPx(double w, int charWidth)
convert character width to pixelstatic int
screenChar256ToPx(int char256, int charWidth)
convert 1/256 character width to pixelstatic int
twipToPoint(int twip)
convert twip (1/20 point) to pointstatic int
twipToPx(int twip)
convert twip (1/20 point) to pixel
-
-
-
Method Detail
-
getDoubleVersion
public static double getDoubleVersion()
-
nextUpdateId
public static String nextUpdateId()
-
isTitleIndexMode
public static boolean isTitleIndexMode(Spreadsheet ss)
Returns whether theSpreadsheet
title is in index mode- Parameters:
ss
- theSpreadsheet
- Returns:
- whether the
Spreadsheet
title is in index mode
-
pxToPoint
public static int pxToPoint(int px)
convert pixel to point
-
pointToPx
public static int pointToPx(int point)
convert point to pixel
-
pxToTwip
public static int pxToTwip(int px)
convert pixel to twip (1/20 point)
-
twipToPx
public static int twipToPx(int twip)
convert twip (1/20 point) to pixel
-
pointToTwip
public static int pointToTwip(int px)
convert point to twip (1/20 point)
-
twipToPoint
public static int twipToPoint(int twip)
convert twip (1/20 point) to point
-
fileChar256ToPx
public static int fileChar256ToPx(int char256, int charWidth)
convert file 1/256 character width to pixel
-
pxToFileChar256
public static int pxToFileChar256(int px, int charWidth)
convert pixel to file 1/256 character width
-
screenChar256ToPx
public static int screenChar256ToPx(int char256, int charWidth)
convert 1/256 character width to pixel
-
pxToScreenChar256
public static int pxToScreenChar256(int px, int charWidth)
Convert pixel to 1/256 character width
-
screenChar1ToPx
public static int screenChar1ToPx(double w, int charWidth)
convert character width to pixel
-
pxToScreenChar1
public static double pxToScreenChar1(int px, int charWidth)
Convert pixel to character width (for application)
-
defaultColumnWidthToPx
public static int defaultColumnWidthToPx(int columnWidth, int charWidth)
Convert default columns character width to pixel
-
-