mirror of
https://github.com/meteoinfo/MeteoInfo.git
synced 2025-12-08 20:36:05 +00:00
update log axis plot functions
This commit is contained in:
parent
5c84f06d89
commit
488dd7811b
@ -842,12 +842,12 @@ public class Plot2D extends AbstractPlot2D {
|
||||
private void drawRectangle(Graphics2D g, RectangleShape rs, PolygonBreak aPGB,
|
||||
boolean isSelected, Rectangle2D area) {
|
||||
Extent extent = rs.getExtent();
|
||||
double[] sXY;
|
||||
sXY = projToScreen(extent.minX, extent.minY + extent.getHeight(), area);
|
||||
double x = sXY[0];
|
||||
double y = sXY[1];
|
||||
double width = this.projXLength(extent.getWidth(), area);
|
||||
double height = this.projYLength(extent.getHeight(), area);
|
||||
double[] xy = projToScreen(extent.minX, extent.minY + extent.getHeight(), area);
|
||||
double x = xy[0];
|
||||
double y = xy[1];
|
||||
xy = projToScreen(extent.maxX, extent.minY, area);
|
||||
double width = Math.abs(xy[0] - x);
|
||||
double height = Math.abs(xy[1] - y);
|
||||
RectangularShape rshape;
|
||||
if (rs.isRound())
|
||||
rshape = new RoundRectangle2D.Double(x, y, width, height, width * rs.getRoundX(), height * rs.getRoundY());
|
||||
|
||||
@ -67,7 +67,7 @@ import java.util.zip.ZipInputStream;
|
||||
public static String getVersion(){
|
||||
String version = GlobalUtil.class.getPackage().getImplementationVersion();
|
||||
if (version == null || version.equals("")) {
|
||||
version = "3.5.8";
|
||||
version = "3.5.9";
|
||||
}
|
||||
return version;
|
||||
}
|
||||
|
||||
@ -1,36 +1,34 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<MeteoInfo File="milconfig.xml" Type="configurefile">
|
||||
<Path OpenPath="D:\Working\MIScript\Jython\mis\common_math\linalg">
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\chart"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\scatter"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\data_process"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\new"/>
|
||||
<Path OpenPath="D:\Working\MIScript\Jython\mis\plot_types\patch">
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\dataframe"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\array"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\io"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\io\micaps"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types\3d"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\model"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\common_math"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\common_math\linalg"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types\plot"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\chart"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\chart\axis"/>
|
||||
<RecentFolder Folder="D:\Working\MIScript\Jython\mis\plot_types\patch"/>
|
||||
</Path>
|
||||
<File>
|
||||
<OpenedFiles>
|
||||
<OpenedFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\model\obj_Lion_1.py"/>
|
||||
<OpenedFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\model\obj_car_1.py"/>
|
||||
<OpenedFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\model\obj_airplane_line.py"/>
|
||||
<OpenedFile File="D:\Working\MIScript\Jython\mis\common_math\linalg\inv_1.py"/>
|
||||
<OpenedFile File="D:\Working\MIScript\Jython\mis\common_math\linalg\pinv_1.py"/>
|
||||
<OpenedFile File="D:\Working\MIScript\Jython\mis\chart\axis\axis_log_2.py"/>
|
||||
</OpenedFiles>
|
||||
<RecentFiles>
|
||||
<RecentFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\model\obj_Lion_1.py"/>
|
||||
<RecentFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\model\obj_car_1.py"/>
|
||||
<RecentFile File="D:\Working\MIScript\Jython\mis\plot_types\3d\jogl\model\obj_airplane_line.py"/>
|
||||
<RecentFile File="D:\Working\MIScript\Jython\mis\common_math\linalg\inv_1.py"/>
|
||||
<RecentFile File="D:\Working\MIScript\Jython\mis\common_math\linalg\pinv_1.py"/>
|
||||
<RecentFile File="D:\Working\MIScript\Jython\mis\chart\axis\axis_log_2.py"/>
|
||||
</RecentFiles>
|
||||
</File>
|
||||
<Font>
|
||||
|
||||
Binary file not shown.
@ -548,6 +548,7 @@ class Axes(object):
|
||||
t_axis = LogAxis(t_axis)
|
||||
t_axis.setMinorTickNum(10)
|
||||
ax.setAxis(t_axis, Location.TOP)
|
||||
ax.setAutoExtent()
|
||||
else:
|
||||
b_axis = Axis(ax.getAxis(Location.BOTTOM))
|
||||
ax.setAxis(b_axis, Location.BOTTOM)
|
||||
@ -597,6 +598,7 @@ class Axes(object):
|
||||
# r_axis.setLabel('Log')
|
||||
r_axis.setMinorTickNum(10)
|
||||
ax.setAxis(r_axis, Location.RIGHT)
|
||||
ax.setAutoExtent()
|
||||
else:
|
||||
l_axis = Axis(ax.getAxis(Location.LEFT))
|
||||
ax.setAxis(l_axis, Location.LEFT)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user