More exquisite bugfixes
git-svn-id: svn://svn.code.sf.net/p/writer2latex/code/trunk@102 f0f2a975-2e09-46c8-9428-3b39399b9f3c
This commit is contained in:
parent
26de5a45df
commit
f19433e716
10 changed files with 95 additions and 43 deletions
|
@ -20,7 +20,7 @@
|
|||
*
|
||||
* All Rights Reserved.
|
||||
*
|
||||
* Version 1.2 (2011-03-16)
|
||||
* Version 1.2 (2011-03-29)
|
||||
*
|
||||
*/
|
||||
|
||||
|
@ -161,8 +161,6 @@ public class Misc{
|
|||
return n;
|
||||
}
|
||||
|
||||
//public static int min(int n, int m) { return n<m ? n : m; }
|
||||
|
||||
public static String truncateLength(String sValue) {
|
||||
if (sValue.endsWith("inch")) {
|
||||
// Cut of inch to in
|
||||
|
@ -173,6 +171,10 @@ public class Misc{
|
|||
}
|
||||
}
|
||||
|
||||
public static boolean isZero(String sValue) {
|
||||
return Math.abs(getFloat(sValue.substring(0, sValue.length()-2),0))<0.001;
|
||||
}
|
||||
|
||||
// Return units per inch for some unit
|
||||
private static final float getUpi(String sUnit) {
|
||||
if ("in".equals(sUnit)) { return 1.0F; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue