mirror of https://gitee.com/cxasm/notepad--.git
cmake/modules: 对 Notepad-- 的构建进行优化,以适用于 Qt Creator 显示
This commit is contained in:
parent
1da49440b6
commit
284d976858
|
@ -8,11 +8,11 @@
|
||||||
if(TRUE)
|
if(TRUE)
|
||||||
# 准备构建 Notepad-- 主程序
|
# 准备构建 Notepad-- 主程序
|
||||||
set(QRC_SOURCES src/RealCompare.qrc)
|
set(QRC_SOURCES src/RealCompare.qrc)
|
||||||
spark_aux_source_paths(CCEditorSources
|
spark_add_executable_path(${PROJECT_NAME}
|
||||||
src
|
${PROJECT_SOURCE_DIR}/src
|
||||||
src/cceditor
|
${PROJECT_SOURCE_DIR}/src/cceditor
|
||||||
)
|
${QRC_SOURCES})
|
||||||
spark_add_executable(${PROJECT_NAME} ${CCEditorSources} ${QRC_SOURCES})
|
|
||||||
target_include_directories(${PROJECT_NAME} PRIVATE
|
target_include_directories(${PROJECT_NAME} PRIVATE
|
||||||
${PROJECT_SOURCE_DIR}/src
|
${PROJECT_SOURCE_DIR}/src
|
||||||
${PROJECT_SOURCE_DIR}/src/cceditor
|
${PROJECT_SOURCE_DIR}/src/cceditor
|
||||||
|
|
|
@ -1,19 +0,0 @@
|
||||||
#pragma once
|
|
||||||
|
|
||||||
#include <QStyledItemDelegate>
|
|
||||||
|
|
||||||
class NdStyledItemDelegate : public QStyledItemDelegate
|
|
||||||
{
|
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
|
||||||
NdStyledItemDelegate(QObject *parent);
|
|
||||||
virtual ~NdStyledItemDelegate();
|
|
||||||
void setFontSize(int size);
|
|
||||||
|
|
||||||
protected:
|
|
||||||
void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const override;
|
|
||||||
|
|
||||||
private:
|
|
||||||
int m_defaultFontSize;
|
|
||||||
};
|
|
Loading…
Reference in New Issue