Fit not ignoring hidden layers

  • Nigel Paton

    Nigel Paton - 2011-02-09


    The Fit method does not ignore hidden layers (m_visible == false). The function that needs to take notice is mpWindow::UpdateBBox(). Possible fix is to change the default mpLayer::HasBBox to return m_visible rather than TRUE.

    If you don't want to change mathplot code just derive a new class from the mathplot layer class and define your own HasBBox that returns m_visible:

        virtual bool   HasBBox() { return (m_visible); }



  • cdron77

    cdron77 - 2011-02-09

    I believe this can be considered a bug, even though the user may want that the bounding box surrounding all data includes also the hidden profiles (this may be useful in some cases).

    Anyway, the behaviour you suggest is more suitable for general cases, so I'll change this in the next release (unless a popular insurrection from the users requires it to be differently).




Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks