Closed cheskos closed 3 years ago
Turns out another change I did was removing
someFormatter.getLinePaint().setStrokeWidth(PixelUtils.dpToPix(5));
but had never had to call the init method on my own. Could this be a bug?
Basically, operations that depend on the screen size/density must occur after PixelUtils has been initialized with a context. Unlikely this is a bug that you are seeing but more of an issue of when/where you are calling
someFormatter.getLinePaint().setStrokeWidth(PixelUtils.dpToPix(5));
.
Manually initializing PixelUtils is a perfectly acceptable solution.
Hi.
I made a small change
plot.setDomainStep(StepMode.SUBDIVIDE, mySize);
toplot.setDomainStep(StepMode.INCREMENT_BY_VAL, mySize);
on an already working section of code and am wondering why I'm getting crashes out of a sudden due to PixelUtils.init() not being called. How does that work? When should I do it on my own and when should I expect the library to do it? I apologize if this question doesn't belong here and should be in SO instead but it's not really a How-to since the plot was working fine previously
Thank you for your time and for writing this library.