History | Log In     View a printable version of the current page.  
Issue Details (XML)

Key: FLEXDMV-1843
Type: Bug Bug
Status: Closed Closed
Resolution: Deferred
Priority: C C
Assignee: Makoto Ichihara
Reporter: Makoto Ichihara
Votes: 2
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Flex Data Visualization Components

When LogAxis.maximum is set to "0 < LogAxis.maximum < 1", it displays in wrong value

Created: 08/18/08 06:35 AM   Updated: 09/08/08 04:19 AM
Component/s: Charts
Security Level: Public (All JIRA Users )

File Attachments: 1. File LogAxisEx.as (0.6 kb)
2. Text File LogAxisTest.mxml (2 kb)

Image Attachments:

1. cap049.png
(22 kb)

2. cap050.png
(23 kb)
Issue Links:
Relationship
 
This issue is related to by:
FLEXDMV-1849 LogAxis.minmum gives wrong value C Closed

Severity: Incorrectly Functioning
Reproducibility: Every Time
Discoverability: Low
Found in Version: DMV 3.0.x
Affected OS(s): Windows - All Windows
Steps to Reproduce:
Steps to reproduce:
1. Run the attached sample code "LogAxisTest.mxml"
2. Enter 0.1 into the now maximum dat field and hit enter
3. LogAxis maximum is displayed as "1" (please see cap049.png)
4. Enter 0.00001 into the now maximum dat field and hit enter
5. LogAxis maximum is displayed as "0.00001" (please see cap050.png)
 
 Actual Results:
Step #3 and Step #5
 
 Expected Results:
 Step #3 should be displayed as "0.1" instead of "1"
 
 Workaround (if any):
Set maximum value like sample below.
For example, if max value is 0.1, set it as 0.011, etc.

package
{
import mx.charts.LogAxis;

public class LogAxisEx extends LogAxis
{
private var my_maximum:Number;

override public function get maximum():Number
{
return my_maximum;
}

override public function set maximum(value:Number):void
{
my_maximum = value;
if(value >= 1){
super.maximum = value;
}
else{
var tmp:Number = value;
switch(value){
case 0.1: tmp = 0.011; break;
case 0.01: tmp = 0.0011; break;
case 0.001: tmp = 0.00011; break;
case 0.0001: tmp = 0.000011; break;
case 0.00001: tmp = 0.0000011; break;
case 0.000001: tmp = 0.00000011; break;
case 0.0000001: tmp = 0.000000011; break;
case 0.00000001: tmp = 0.0000000011; break;
case 0.000000001: tmp = 0.00000000011; break;
case 0.0000000001: tmp = 0.000000000011; break;
}
super.maximum = tmp;
}
}

}
}

 
 
 
Language Found: English
Bugbase Id: none
Triaged: Yes
Regression: No
QA Owner: Sangavi Gururaghavendran
Resolved by: Jyoti Kishnani
Fixed Version: (Planning) DMV Post Moxie - Next Build
Confirmed Version: DMV 3.0.x - 202392
Participants: Kurt Mossman, Makoto Ichihara and Sudhir Manjunath


 All   Comments      Sort Order:
Kurt Mossman - [08/18/08 06:44 PM ]

Within LogAxis.as changing Math.ceil to Math.floor below resolves this problem.

public function set maximum(value:Number):void
{
computedMaximum = Math.floor(Math.log(value) / Math.LN10);
assignedMaximum = computedMaximum;

invalidateCache();

dispatchEvent(new Event("mappingChange"));
dispatchEvent(new Event("axisChange"));
}

Kurt Mossman - [08/18/08 07:08 PM ]
LogAxisEx.as will work around this problem.

Makoto Ichihara - [08/19/08 01:41 AM ]
Thank you so much, Kurt.
In case of the maximum is bigger than "1", we added one "if" statement.

override public function set maximum(value:Number):void
{
if(value < 1){
computedMaximum = Math.floor(Math.log(value) / Math.LN10);
}
else{
computedMaximum = Math.ceil(Math.log(value) / Math.LN10);
}

assignedMaximum = computedMaximum;

invalidateCache();

dispatchEvent(new Event("mappingChange"));
dispatchEvent(new Event("axisChange"));
}


Sudhir Manjunath - [08/27/08 07:58 AM ]
This issue occurs in 2.0.1 version also