summaryrefslogtreecommitdiffstats
path: root/src/kile/previewconfigwidget.h
blob: a05a361850ecfe431ee89a28e0f81659405a3bc2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
/***************************************************************************
    date                 : Sep 05 2006
    version              : 0.32
    copyright            : (C) 2005-2006 by Holger Danielsson
    email                : holger.danielsson@t-online.de
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   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 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#ifndef PREVIEWCONFIGWIDGET_H
#define PREVIEWCONFIGWIDGET_H

#include "quickpreview.h"

#include <tqwidget.h>
#include <tqcheckbox.h>
#include <tqgroupbox.h>
#include <kcombobox.h>
#include <klineedit.h>
#include <tdeconfig.h>

/**
  *@author Holger Danielsson
  */

class KileWidgetPreviewConfig : public TQWidget
{
	Q_OBJECT
  
public: 
	KileWidgetPreviewConfig(TDEConfig *config, KileTool::QuickPreview *preview, TQWidget *parent=0, const char *name=0);
	~KileWidgetPreviewConfig() {}

	void readConfig(void);
	void writeConfig(void);

private:
	TDEConfig *m_config;
	KComboBox *m_combobox;
	KileTool::QuickPreview *m_preview;
	KLineEdit *m_leDvipngResolution;
	TQLabel *m_lbDvipng, *m_lbConvert, *m_lbMathgroup;
	TQCheckBox *m_cbEnvironment, *m_cbSelection, *m_cbMathgroup;
	KComboBox *m_coSelection, *m_coEnvironment;
	TQGroupBox *m_gbPreview;

	bool m_dvipngInstalled, m_convertInstalled;

	int tool2index(int tool);
	int index2tool(int index);
	int installedTools();

	void setupSeparateWindow();
	void setupBottomBar();
	void setupProperties();

private slots:
	void updateConversionTools();
};

#endif