You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
655 B
28 lines
655 B
3 years ago
|
package com.fr.design.mainframe;
|
||
4 years ago
|
|
||
|
import com.fr.stable.Constants;
|
||
|
import com.fr.stable.unit.LEN_UNIT;
|
||
|
|
||
|
public class PX extends LEN_UNIT {
|
||
|
private static final long FU_SCALE = 36576L;
|
||
|
|
||
|
public PX(float var1) {
|
||
|
super(var1);
|
||
|
}
|
||
|
|
||
|
|
||
|
public boolean equals(Object var1) {
|
||
|
return var1 instanceof PX && super.equals(var1);
|
||
|
}
|
||
|
|
||
|
protected long getMoreFUScale() {
|
||
|
int dpi = DesignerUIModeConfig.getInstance().getScreenResolution();
|
||
|
return FU_SCALE / dpi;
|
||
|
}
|
||
|
|
||
|
public static double toPixWithResolution(double value, int resolution) {
|
||
|
return value * resolution / Constants.FR_PAINT_RESOLUTION;
|
||
|
}
|
||
|
|
||
|
}
|