Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Education
KmPlot
Commits
3161447f
Commit
3161447f
authored
Oct 01, 2019
by
Laurent Montel
Browse files
Port some deprecated methods
parent
09ac74dc
Changes
9
Hide whitespace changes
Inline
Side-by-side
kmplot/coordsconfigdialog.cpp
View file @
3161447f
...
...
@@ -48,7 +48,7 @@ CoordsConfigDialog::CoordsConfigDialog(QWidget *parent)
configAxesDialog
->
kcfg_XMin
->
setTabChain
(
configAxesDialog
->
kcfg_XMax
->
focusProxy
()
);
configAxesDialog
->
kcfg_XMax
->
setTabChain
(
configAxesDialog
->
kcfg_YMin
->
focusProxy
()
);
configAxesDialog
->
kcfg_YMin
->
setTabChain
(
configAxesDialog
->
kcfg_YMax
->
focusProxy
()
);
configAxesDialog
->
layout
()
->
set
Margin
(
0
);
configAxesDialog
->
layout
()
->
set
ContentsMargins
(
0
,
0
,
0
,
0
);
addPage
(
configAxesDialog
,
i18n
(
"Coordinates"
),
"coords"
,
i18n
(
"Coordinate System"
)
);
setWindowTitle
(
i18n
(
"Coordinate System"
)
);
setHelp
(
"axes-config"
);
...
...
kmplot/equationedit.cpp
View file @
3161447f
...
...
@@ -58,7 +58,7 @@ EquationEdit::EquationEdit( QWidget * parent )
connect
(
m_equationEditWidget
,
&
EquationEditWidget
::
cursorPositionChanged
,
this
,
&
EquationEdit
::
reHighlight
);
QHBoxLayout
*
layout
=
new
QHBoxLayout
(
this
);
layout
->
set
Margin
(
0
);
layout
->
set
ContentsMargins
(
0
,
0
,
0
,
0
);
layout
->
addWidget
(
m_equationEditWidget
);
layout
->
addWidget
(
m_editButton
);
}
...
...
kmplot/functioneditor.cpp
View file @
3161447f
...
...
@@ -113,7 +113,7 @@ FunctionEditor::FunctionEditor( QMenu * createNewPlotsMenu, QWidget * parent )
//END initialize equation edits
for
(
unsigned
i
=
0
;
i
<
5
;
++
i
)
m_editor
->
stackedWidget
->
widget
(
i
)
->
layout
()
->
set
Margin
(
0
);
m_editor
->
stackedWidget
->
widget
(
i
)
->
layout
()
->
set
ContentsMargins
(
0
,
0
,
0
,
0
);
connect
(
m_editor
->
deleteButton
,
&
QPushButton
::
clicked
,
this
,
&
FunctionEditor
::
deleteCurrent
);
connect
(
m_functionList
,
&
FunctionListWidget
::
currentItemChanged
,
this
,
&
FunctionEditor
::
functionSelected
);
...
...
kmplot/initialconditionseditor.cpp
View file @
3161447f
...
...
@@ -106,13 +106,13 @@ QVariant InitialConditionsModel::data( const QModelIndex & index, int role ) con
case
Qt
::
TextAlignmentRole
:
return
Qt
::
AlignLeft
;
case
Qt
::
TextColor
Role
:
case
Qt
::
Foreground
Role
:
return
QColor
(
Qt
::
black
);
case
Qt
::
WhatsThisRole
:
case
Qt
::
AccessibleDescriptionRole
:
case
Qt
::
CheckStateRole
:
case
Qt
::
Background
Color
Role
:
case
Qt
::
BackgroundRole
:
case
Qt
::
SizeHintRole
:
case
Qt
::
FontRole
:
case
Qt
::
UserRole
:
...
...
@@ -273,7 +273,7 @@ InitialConditionsEditor::InitialConditionsEditor( QWidget * parent )
m_equation
=
0
;
setupUi
(
this
);
layout
()
->
set
Margin
(
0
);
layout
()
->
set
ContentsMargins
(
0
,
0
,
0
,
0
);
connect
(
addButton
,
&
QPushButton
::
clicked
,
this
,
&
InitialConditionsEditor
::
add
);
connect
(
removeButton
,
&
QPushButton
::
clicked
,
this
,
&
InitialConditionsEditor
::
remove
);
...
...
kmplot/kgradientdialog.cpp
View file @
3161447f
...
...
@@ -393,7 +393,7 @@ KGradientDialog::KGradientDialog( QWidget * parent, bool modal )
//BEGIN layout widgets
QVBoxLayout
*
layout
=
new
QVBoxLayout
(
this
);
layout
->
set
Margin
(
0
);
layout
->
set
ContentsMargins
(
0
,
0
,
0
,
0
);
m_gradient
->
setFixedHeight
(
24
);
layout
->
addWidget
(
m_gradient
);
...
...
kmplot/kparametereditor.cpp
View file @
3161447f
...
...
@@ -65,7 +65,7 @@ KParameterEditor::KParameterEditor( QList<Value> *l, QWidget *parent )
connect
(
buttonBox
,
&
QDialogButtonBox
::
rejected
,
this
,
&
KParameterEditor
::
reject
);
mainLayout
->
addWidget
(
buttonBox
);
mainLayout
->
set
Margin
(
0
);
mainLayout
->
set
ContentsMargins
(
0
,
0
,
0
,
0
);
m_mainWidget
->
cmdNew
->
setIcon
(
QIcon
::
fromTheme
(
"document-new"
)
);
m_mainWidget
->
cmdDelete
->
setIcon
(
QIcon
::
fromTheme
(
"edit-delete"
)
);
...
...
kmplot/plotstylewidget.cpp
View file @
3161447f
...
...
@@ -72,7 +72,7 @@ PlotStyleWidget::PlotStyleWidget( QWidget * parent )
m_dialog
->
setWindowTitle
(
i18n
(
"Plot Appearance"
)
);
m_dialogWidget
=
new
PlotStyleDialogWidget
(
m_dialog
);
m_dialogWidget
->
layout
()
->
set
Margin
(
0
);
m_dialogWidget
->
layout
()
->
set
ContentsMargins
(
0
,
0
,
0
,
0
);
mainLayout
->
addWidget
(
m_dialogWidget
);
QDialogButtonBox
*
buttonBox
=
new
QDialogButtonBox
(
QDialogButtonBox
::
Ok
);
...
...
kmplot/view.cpp
View file @
3161447f
...
...
@@ -44,7 +44,7 @@
#include
<QResizeEvent>
#include
<QSlider>
#include
<QTextEdit>
#include
<QTime>
#include
<Q
Elapsed
Time
r
>
#include
<QTimer>
// KDE includes
...
...
@@ -114,7 +114,7 @@ View::View( bool readOnly, QMenu * functionPopup, QWidget* parent )
m_textEdit
->
setLineWrapMode
(
QTextEdit
::
NoWrap
);
m_textDocument
=
m_textEdit
->
document
();
m_mousePressTimer
=
new
QTime
();
m_mousePressTimer
=
new
Q
Elapsed
Time
r
();
new
ViewAdaptor
(
this
);
QDBusConnection
::
sessionBus
().
registerObject
(
"/view"
,
this
);
...
...
@@ -3404,7 +3404,7 @@ void View::leaveEvent(QEvent *)
void
View
::
wheelEvent
(
QWheelEvent
*
e
)
{
m_AccumulatedDelta
+=
e
->
delta
();
m_AccumulatedDelta
+=
e
->
angleDelta
().
y
();
if
(
e
->
modifiers
()
&
Qt
::
ControlModifier
)
{
...
...
kmplot/view.h
View file @
3161447f
...
...
@@ -48,8 +48,8 @@ class MainDlg;
class
QPaintEvent
;
class
QTextDocument
;
class
KTextEdit
;
class
QTime
;
class
QMenu
;
class
QElapsedTimer
;
//@{
/// Some abbreviations for horizontal and vertical lines.
...
...
@@ -616,7 +616,7 @@ class View : public QWidget
/// for translating the view via dragging
QPoint
m_prevDragMousePos
;
/// timer that is started when the mouse is pressed
Q
Time
*
m_mousePressTimer
;
QElapsed
Time
r
*
m_mousePressTimer
;
/** Current plot viewport. */
const
QRectF
getViewport
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment