scribblearea.cpp
bool ScribbleArea::openImage(const QString &fileName)
{
    // Holds the image
    QImage loadedImage;

    // If the image wasn't loaded leave this function
    if (!loadedImage.load(fileName))
        return false;

    QSize newSize = loadedImage.size().expandedTo(size());
    resizeImage(&loadedImage, newSize);
    image = loadedImage;
    modified = false;
    update();
    return true;
}
// Used to load the image and place it in the widget
Used to load the image and place it in the widget
Used to load the image and place it in the widget
bool ScribbleArea::openImage(const QString &fileName)
{
    QImage loadedImage;
    if (!loadedImage.load(fileName))
        return false;
    QSize newSize = loadedImage.size().expandedTo(size());
    resizeImage(&loadedImage, newSize);
    image = loadedImage;
    modified = false;
    update();
    return true;
}
bool ScribbleArea :: openImage ( const QString & fileName ) { QImage loadedImage ; if ( ! loadedImage . load ( fileName ) ) return false ; QSize newSize = loadedImage . size ( ) . expandedTo ( size ( ) ) ; resizeImage ( & loadedImage , newSize ) ; image = loadedImage ; modified = false ; update ( ) ; return true ; }
Used to load the image and place it in the widget
Used to load the image and place it in the widget
// Holds the image // If the image wasn't loaded leave this function