// $Id: profilechecker.h,v 1.9 2008/02/19 21:02:27 hvengel Exp $
//  Lttle cms Profiler
//  Copyright (C) 1998-2001 Marti Maria
// Copyright (C) 2005 Hal Engel
//
// THIS SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
// EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
// WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
//
// IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
// INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
// OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
// WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF
// LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
// OF THIS SOFTWARE.
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
// 
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
// 
// You should have received a copy of the GNU General Public License
// along with this program.  If not, see <http://www.gnu.org/licenses/>.
//
// Version 1.11
#ifndef PROFILECHECKER_H
#define PROFILECHECKER_H

#include "ui_profilecheckerbase.h"
#include "lcmsprf.h"
#include <qtlcmswidgets.h>
//Added by qt3to4:
#include <QResizeEvent>

class  ProfileChecker : public QDialog, private Ui::ProfileCheckerBase
{
    Q_OBJECT

public:

    ProfileChecker(QWidget *parent = 0 );
    virtual ~ProfileChecker();

public slots:

    virtual void slotGO();
    virtual void slotSelectOutputFile();
    virtual void slotChangeCurve();
    virtual void slotUpdateLabels();
    virtual void slotSelectScanoutIT8();
    virtual void slotChangeCorrection(int);
    virtual void slotHideTagetSelectorIfNeeded();

protected slots:
    void slotHelpButton();
    void isAllReady();

protected:

    virtual void resizeEvent(QResizeEvent* );

    void ResetData(BOOL lFree = FALSE);

    void SetInputProfile(const QString OutputFile);
    void SetScanoutFile(const QString ScanoutFile);

    int  GetIntent(void);

    void InspectProfile();

    void ResetMeasurement(BOOL lFree);
    void RedrawTonge();
    void RedrawCurve();

    // The Data

    CheckProfile * Checker;

    char ReferenceSheet[MAX_PATH];
    char MeasurementSheet[MAX_PATH];
    char OutputProfileFile[MAX_PATH];

    MEASUREMENT m;

    icColorSpaceSignature ProfileColorSpace;
    icColorSpaceSignature PCSColorSpace;
    int nChennels;

    cmsCIExyYTRIPLE Primaries;
    cmsCIEXYZ MediaWhite;

    LPGAMMATABLE TRC[3];
    LPGAMMATABLE A2B0Pre[3][MAXCHANNELS];
    LPGAMMATABLE A2B0Post[3][MAXCHANNELS];
    LPGAMMATABLE B2A0Pre[3][MAXCHANNELS];
    LPGAMMATABLE B2A0Post[3][MAXCHANNELS];

    char* CharTarget;
    size_t CharTargetSize;
};

#endif
