@@ -926,23 +926,44 void QAbstractAxisPrivate::initializeTheme(ChartTheme* theme, bool forced) | |||
|
926 | 926 | |
|
927 | 927 | bool axisX = m_orientation == Qt::Horizontal; |
|
928 | 928 | |
|
929 | //TODO: introduce axis brush | |
|
930 | if (m_visible) { | |
|
929 | 931 | if (m_arrowVisible) { |
|
930 | ||
|
932 | if (forced || pen == m_axisPen) { | |
|
933 | q_ptr->setLinePen(theme->axisLinePen()); | |
|
934 | } | |
|
935 | } | |
|
936 | if (m_gridLineVisible) { | |
|
937 | if (forced || pen == m_gridLinePen) { | |
|
938 | q_ptr->setGridLinePen(theme->girdLinePen()); | |
|
939 | } | |
|
940 | } | |
|
941 | if (m_labelsVisible) { | |
|
931 | 942 | if (forced || brush == m_labelsBrush){ |
|
932 | 943 | q_ptr->setLabelsBrush(theme->labelBrush()); |
|
933 | 944 | } |
|
934 | //TODO: introduce axis brush | |
|
935 | if (forced || brush == m_titleBrush){ | |
|
936 | q_ptr->setTitleBrush(theme->labelBrush()); | |
|
937 | } | |
|
938 | 945 | if (forced || pen == m_labelsPen){ |
|
939 | 946 | q_ptr->setLabelsPen(Qt::NoPen);// NoPen for performance reasons |
|
940 | 947 | } |
|
948 | if (forced || font == m_labelsFont){ | |
|
949 | q_ptr->setLabelsFont(theme->labelFont()); | |
|
950 | } | |
|
951 | } | |
|
952 | if (m_titleVisible) { | |
|
953 | if (forced || brush == m_titleBrush){ | |
|
954 | q_ptr->setTitleBrush(theme->labelBrush()); | |
|
955 | } | |
|
941 | 956 | if (forced || pen == m_titlePen){ |
|
942 | 957 | q_ptr->setTitlePen(Qt::NoPen);// Noen for performance reasons |
|
943 | 958 | } |
|
959 | //TODO: discuss with Tero | |
|
960 | if (forced || font == m_titleFont){ | |
|
961 | QFont font(m_labelsFont); | |
|
962 | font.setBold(true); | |
|
963 | q_ptr->setTitleFont(font); | |
|
964 | } | |
|
965 | } | |
|
944 | 966 | if (forced || m_shadesVisible) { |
|
945 | ||
|
946 | 967 | if (forced || brush == m_shadesBrush){ |
|
947 | 968 | q_ptr->setShadesBrush(theme->backgroundShadesBrush()); |
|
948 | 969 | } |
@@ -955,24 +976,6 void QAbstractAxisPrivate::initializeTheme(ChartTheme* theme, bool forced) | |||
|
955 | 976 |
|
|
956 | 977 | } |
|
957 | 978 | } |
|
958 | ||
|
959 | if (forced || pen == m_axisPen) { | |
|
960 | q_ptr->setLinePen(theme->axisLinePen()); | |
|
961 | } | |
|
962 | ||
|
963 | if (forced || pen == m_gridLinePen) { | |
|
964 | q_ptr->setGridLinePen(theme->girdLinePen()); | |
|
965 | } | |
|
966 | ||
|
967 | if (forced || font == m_labelsFont){ | |
|
968 | q_ptr->setLabelsFont(theme->labelFont()); | |
|
969 | } | |
|
970 | //TODO: discuss with Tero | |
|
971 | if (forced || font == m_titleFont){ | |
|
972 | QFont font(m_labelsFont); | |
|
973 | font.setBold(true); | |
|
974 | q_ptr->setTitleFont(font); | |
|
975 | } | |
|
976 | 979 | } |
|
977 | 980 | } |
|
978 | 981 |
General Comments 0
You need to be logged in to leave comments.
Login now