Skip to content
Snippets Groups Projects
Commit 27924f97 authored by Wuttke, Joachim's avatar Wuttke, Joachim
Browse files

bugfix rounding of axes

parent dc8346a1
No related branches found
No related tags found
No related merge requests found
......@@ -3,7 +3,6 @@ SHOWSTOPPER TOFTOF
-Fehlerbalken
BUGS
- S(2th,w) statt S(q,w)
WISHLIST TOFTOF
- Symbolerklärungen zu Plot
......@@ -15,7 +14,6 @@ WISHLIST TOFTOF
WISHLIST JWu
- distribute wupscat, wupsbb
- frida.ini location via -D ?
- restore ask callback help for lists (prompt for list, not for string)
- restore help on "?"
- wenn oio mehrere einzelne Spektren liefert, automatisch in einen File packen
......@@ -29,6 +27,11 @@ CHECK - gd: commandos -> gnuplot (für Fanni)
- mfj remove redundant doc lines
- dp output for #spec>1 is obfuscated
- customization
- frida.ini location via -D
- private ini file
- additional settings: graph mode
SEBASTIAN
= erledigt =
......@@ -38,6 +41,7 @@ SEBASTIAN
- in calc mode: ni[0.1] should not exit calc mode
- after "g\n": gxl is mixed up with gxf+/gxf-
- when oio is called with parameter, do not print list
- deal better with inf scale
= vorrangig =
......@@ -64,7 +68,6 @@ SEBASTIAN
- allow "for loops" in fit functions
- cut file with many z values
- allow a w-dependent expression for the resolution
- deal better with inf scale
- make comments in ps file complete (was somehow not complete in the apparent elastic intensity case)
- extract these commands from a ps file and "\i" it (to change limits, for example)
- command to show only fit function (and then possibly "> file.txt")
......
- major code refactoring:
- online memory and z-entry main vector now based on shared_ptr
- sources split (olf/mem, opr/special1, dualplot/axis)
- scan and parts of curve now unified in zentry
- reduce .h dependencies (keyword "class"; move implementation to .cpp)
- suppress menu when answer is already given (oio, ..)
- bugfix in plot axis rounding
- bugfix mfj: z coordinates, rPar
- add \wh meta command: write history, using GNU history
- purge and simplify macro engine; separate meta commands and macros
......
......@@ -89,13 +89,13 @@ void CAxis::setRoundedLimits( string axnam, double _inf, double _sup )
static double digits = 2;
if ( _inf==-INFINITY || _sup==+INFINITY )
throw "unexpected inf limits when rounding " + axnam + " plot range";
if( _inf>=_sup )
throw "Cannot round " + axnam + " plot range " +
strg(_inf) + " .. " + strg(_sup);
throw "BUG: rounding " + axnam + " limits: unexpected inf limits";
if( _inf>_sup )
throw "BUG: rounding " + axnam + " limits: invalid plot range " +
strg(_inf) + " > " + strg(_sup);
if( logflag && _inf<=0 )
throw "Cannot round log " + axnam + " plot range " +
strg(_inf) + " .. " + strg(_sup);
throw "BUG: rounding " + axnam + " limits: nonpositive log inf " +
strg(_inf);
inf = _inf;
sup = _sup;
......@@ -104,9 +104,15 @@ void CAxis::setRoundedLimits( string axnam, double _inf, double _sup )
if( logflag ){
inf /= 10;
sup *= 10;
} else if ( inf>0 ) {
inf *= 0.9;
sup *= 1.1;
} else if ( sup<0 ) {
inf *= 1.1;
sup *= 0.9;
} else {
inf -= 1;
sup += 1;
inf = -1;
sup = +1;
}
return;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment