~kst-plot/kst/debian-xenial

« back to all changes in this revision

Viewing changes to src/datasources/ascii/asciiconfigwidget.h

  • Committer: Steven Benton
  • Date: 2012-11-04 22:45:35 UTC
  • mfrom: (1.2.10)
  • Revision ID: stevebenton@rogers.com-20121104224535-mnnvrp4mhvuz0h2p
* New upstream release.
* Non-maintainer upload.
* Remove patches that have been resolved upstream:
  - desktop-entry-contains-encoding-key.diff
  - desktop-entry-lacks-main-category.diff
    - upstream uses Education category rather than Graphics
  - fix-qreal-vs-double-for-arm.diff
* kst package Replaces and Conflicts with kst2 -- for old PPA users only

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/***************************************************************************
 
2
 *                                                                         *
 
3
 *   Copyright : (C) 2003 The University of Toronto                        *
 
4
 *   email     : netterfield@astro.utoronto.ca                             *
 
5
 *                                                                         *
 
6
 *   This program is free software; you can redistribute it and/or modify  *
 
7
 *   it under the terms of the GNU General Public License as published by  *
 
8
 *   the Free Software Foundation; either version 2 of the License, or     *
 
9
 *   (at your option) any later version.                                   *
 
10
 *                                                                         *
 
11
 ***************************************************************************/
 
12
 
 
13
#ifndef ASCII_CONFIG_WINDGET_H
 
14
#define ASCII_CONFIG_WINDGET_H
 
15
 
 
16
#include "asciisource.h"
 
17
#include "dataplugin.h"
 
18
 
 
19
#include "ui_asciiconfig.h"
 
20
 
 
21
class QTextStream;
 
22
 
 
23
class AsciiConfigWidgetInternal : public QWidget, public Ui_AsciiConfig
 
24
{
 
25
  Q_OBJECT
 
26
 
 
27
  public:
 
28
    AsciiConfigWidgetInternal(QWidget *parent);
 
29
 
 
30
    AsciiSourceConfig config();
 
31
    void setConfig(const AsciiSourceConfig&);
 
32
    void setFilename(const QString& filename);
 
33
 
 
34
  private Q_SLOTS:
 
35
    void columnLayoutChanged(int);
 
36
    void showBeginning();
 
37
    void updateUnitLineEnabled(bool);
 
38
    void updateFrameBuffer(bool);
 
39
    void updateFormatString();
 
40
 
 
41
  private:
 
42
    const int _index_offset;
 
43
    QString _filename;
 
44
    QString readLine(QTextStream& in, int maxLength);
 
45
};
 
46
 
 
47
 
 
48
class AsciiConfigWidget : public Kst::DataSourceConfigWidget
 
49
{
 
50
  public:
 
51
    AsciiConfigWidget(QSettings&);
 
52
    ~AsciiConfigWidget();
 
53
 
 
54
    void load();
 
55
    void save();
 
56
    bool isOkAcceptabe() const;
 
57
 
 
58
    void setFilename(const QString& filename);
 
59
 
 
60
    AsciiConfigWidgetInternal *_ac;
 
61
    AsciiSourceConfig _oldConfig;
 
62
};
 
63
 
 
64
 
 
65
 
 
66
#endif
 
67
// vim: ts=2 sw=2 et