qse  0.5.4
Functions
qsegraphscansmodel.cpp File Reference
#include "qsegraphscansmodel.h"
#include "qsedataset.h"
#include <QBrush>
#include <QTableView>
#include <stdio.h>
Include dependency graph for qsegraphscansmodel.cpp:

Go to the source code of this file.

Functions

static int min (int a, int b)
 
static const char * role_string (int role)
 

Function Documentation

static int min ( int  a,
int  b 
)
static

Definition at line 124 of file qsegraphscansmodel.cpp.

Referenced by QseGraphScansModel::data().

125 {
126  if (a<b) {
127  return a;
128  } else {
129  return b;
130  }
131 }
static const char* role_string ( int  role)
static

Definition at line 134 of file qsegraphscansmodel.cpp.

135 {
136  switch (role) {
137  case Qt::DisplayRole:
138  return "Qt::DisplayRole";
139  break;
140  case Qt::DecorationRole:
141  return "Qt::DecorationRole";
142  break;
143  case Qt::EditRole:
144  return "Qt::EditRole";
145  break;
146  case Qt::ToolTipRole:
147  return "Qt::ToolTipRole";
148  break;
149  case Qt::StatusTipRole:
150  return "Qt::StatusTipRole";
151  break;
152  case Qt::WhatsThisRole:
153  return "Qt::WhatsThisRole";
154  break;
155  case Qt::SizeHintRole:
156  return "Qt::SizeHintRole";
157  break;
158  case Qt::FontRole:
159  return "Qt::FontRole";
160  break;
161  case Qt::TextAlignmentRole:
162  return "Qt::TextAlignmentRole";
163  break;
164  case Qt::BackgroundRole:
165  return "Qt::BackgroundRole";
166  break;
167 // case Qt::BackgroundColorRole:
168 // return "Qt::BackgroundColorRole";
169 // break;
170  case Qt::ForegroundRole:
171  return "Qt::ForegroundRole";
172  break;
173 // case Qt::TextColorRole:
174 // return "Qt::TextColorRole";
175 // break;
176  case Qt::CheckStateRole:
177  return "Qt::CheckStateRole";
178  break;
179  case Qt::AccessibleTextRole:
180  return "Qt::AccessibleTextRole";
181  break;
182  case Qt::AccessibleDescriptionRole:
183  return "Qt::AccessibleDescriptionRole";
184  break;
185  case Qt::UserRole:
186  return "Qt::UserRole";
187  break;
188  default:
189  return "Other role";
190  }
191 }