mirror of
https://github.com/jkriege2/JKQtPlotter.git
synced 2024-12-25 10:01:38 +08:00
fixed issue described in PR #62: Fix custom labels draw, because giving exactly two label-strings did not display all of them, thanks to github_user:FalsinSoft
This commit is contained in:
parent
a80ea3a24a
commit
94f80510ec
@ -14,6 +14,7 @@ This page lists release notes for the diferent version of JKQTPlotter
|
|||||||
\subsection page_whatsnew_TRUNK_OVERVIEW trunk: Overview
|
\subsection page_whatsnew_TRUNK_OVERVIEW trunk: Overview
|
||||||
Changes, compared to \ref page_whatsnew_V4_0_0 "v4.0.0" include:
|
Changes, compared to \ref page_whatsnew_V4_0_0 "v4.0.0" include:
|
||||||
<ul>
|
<ul>
|
||||||
|
<li>fixed issue described in <a href="https://github.com/jkriege2/JKQtPlotter/pull/62">#62: Fix custom labels draw, because giving exactly two label-strings did not display all of them</a>, thanks to <a href="https://github.com/FalsinSoft">user:FalsinSoft</a></li>
|
||||||
<li>fixed issue <a href="https://github.com/jkriege2/JKQtPlotter/pull/70">#70: Typo in jkqtplotter/CMakeLists.txt</a>, thanks to <a href="https://github.com/tedlinlab">user:tedlinlab</a></li>
|
<li>fixed issue <a href="https://github.com/jkriege2/JKQtPlotter/pull/70">#70: Typo in jkqtplotter/CMakeLists.txt</a>, thanks to <a href="https://github.com/tedlinlab">user:tedlinlab</a></li>
|
||||||
<li>NEW: JKQTPFilledCurveXGraph and JKQTPFilledCurveYGraph can now plot wiggle plots with different fill styles above and below the baseline (feature request <a href="https://github.com/jkriege2/JKQtPlotter/issues/68">#68 Wiggle Plots</a> from <a href="https://github.com/xichaoqiang">user:xichaoqiang</a> </li>
|
<li>NEW: JKQTPFilledCurveXGraph and JKQTPFilledCurveYGraph can now plot wiggle plots with different fill styles above and below the baseline (feature request <a href="https://github.com/jkriege2/JKQtPlotter/issues/68">#68 Wiggle Plots</a> from <a href="https://github.com/xichaoqiang">user:xichaoqiang</a> </li>
|
||||||
</ul>
|
</ul>
|
||||||
|
@ -1011,14 +1011,10 @@ bool JKQTPCoordinateAxis::getNextLabel(double& x, QString& label, bool init) {
|
|||||||
return (tickLabels.size()>0);
|
return (tickLabels.size()>0);
|
||||||
} else {
|
} else {
|
||||||
for (int i=0; i<tickLabels.size(); i++) {
|
for (int i=0; i<tickLabels.size(); i++) {
|
||||||
if (x==tickLabels[i].first && i+1<tickLabels.size()) {
|
if (fabs(x-tickLabels[i].first)<1e-30 && i+1<tickLabels.size()) {
|
||||||
if (x>=axismin && x<=axismax) {
|
label=tickLabels[i+1].second;
|
||||||
label=tickLabels[i+1].second;
|
x=tickLabels[i+1].first;
|
||||||
x=tickLabels[i+1].first;
|
return (x>=axismin && x<=axismax);
|
||||||
return true;
|
|
||||||
} else {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user