Skip to content

Bitmap::valid() reversed in 3.0 #190

@Randalphwa

Description

@Randalphwa

Previously, I used:

if ( bmp.valid() )

to verify that Document->render...() created a valid bitmap. With 3.0, Bitmap::valid() returns false if the bitmap exists whereas previously it returned true. It took me a while to find the problem, and I see that valid() is documented as deprecated but not marked as such. It certainly should not be used in it's current form since the correct check would now be:

if ( !bmp.valid() )

I.e., if valid returns false then the bitmap is valid.

Could this be either reversed back to it's original meaning so it doesn't break existing code, or marked as deprecated so that at least there is a compiler warning when using it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingquestionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions