19package org.openoffice.xmerge.util;
34 float inches = (float)
value/1440;
35 float cm = inches*(float)2.54;
47 int twips = (
int) ((
value/2.54)*1440);
59 return (
int) (
value*1440);
74 if ((posi =
value.indexOf(
"cm")) != -1) {
77 }
else if ((posi =
value.indexOf(
"inch")) != -1) {
78 float inches =
Float.parseFloat(
value.substring(0,posi));
Helper class providing static methods to convert data to/from twips.
static int convert2twips(String value, int defaultValue)
Convert String to twips.
static int inches2twips(float value)
Convert from cm's to twips.
static float twips2cm(int value)
Convert from twips to cm's.
static int cm2twips(float value)
Convert from cm's to twips.
const wchar_t *typedef int(__stdcall *DllNativeUnregProc)(int