VS2022 设置(界面、选项卡宽度、代码编辑器颜色,字体颜色,对比度等等)

笔者是个弱视,电脑缩放比例一般是125%,也喜欢强对比度的环境,以下都是这个方向的设置。

ps: 如题,用的是VS2022, 不需要额外的插件

先看效果:
在这里插入图片描述

背景颜色、字体颜色、括号对着色

背景颜色

在这里插入图片描述

字体颜色

在这里插入图片描述

括号对着色

在这里插入图片描述

选项卡宽度

在这里插入图片描述

调整解决方案配置宽度

在这里插入图片描述
步骤:
1.
在这里插入图片描述
2.
在这里插入图片描述

多行选项卡、选项卡颜色

在这里插入图片描述
在这里插入图片描述

  • 0
    点赞
  • 11
    收藏
    觉得还不错? 一键收藏
  • 4
    评论
以下是一个简单的Qt界面代码,其中包括了字体、字体颜色和工具的设置。你可以根据需要进行修改和扩展。 ```cpp #include <QtWidgets> int main(int argc, char *argv[]) { QApplication app(argc, argv); QWidget *window = new QWidget; window->setWindowTitle("Text Editor"); // 创建字体、颜色和工具选择器 QFontComboBox *fontComboBox = new QFontComboBox; QComboBox *colorComboBox = new QComboBox; colorComboBox->addItem("Black", QColor(Qt::black)); colorComboBox->addItem("Red", QColor(Qt::red)); colorComboBox->addItem("Green", QColor(Qt::green)); colorComboBox->addItem("Blue", QColor(Qt::blue)); QToolBar *toolBar = new QToolBar; toolBar->addWidget(fontComboBox); toolBar->addWidget(colorComboBox); // 创建文本编辑框 QTextEdit *textEdit = new QTextEdit; // 在工具栏中添加加粗、斜体、下划线按钮 QAction *boldAction = new QAction("Bold", toolBar); boldAction->setCheckable(true); boldAction->setIcon(QIcon(":/images/bold.png")); QAction *italicAction = new QAction("Italic", toolBar); italicAction->setCheckable(true); italicAction->setIcon(QIcon(":/images/italic.png")); QAction *underlineAction = new QAction("Underline", toolBar); underlineAction->setCheckable(true); underlineAction->setIcon(QIcon(":/images/underline.png")); toolBar->addAction(boldAction); toolBar->addAction(italicAction); toolBar->addAction(underlineAction); // 连接工具栏按钮信号和槽函数 QObject::connect(fontComboBox, SIGNAL(currentFontChanged(QFont)), textEdit, SLOT(setCurrentFont(QFont))); QObject::connect(colorComboBox, SIGNAL(currentIndexChanged(int)), textEdit, SLOT(setTextColor(QColor))); QObject::connect(boldAction, SIGNAL(toggled(bool)), textEdit, SLOT(setBold(bool))); QObject::connect(italicAction, SIGNAL(toggled(bool)), textEdit, SLOT(setItalic(bool))); QObject::connect(underlineAction, SIGNAL(toggled(bool)), textEdit, SLOT(setUnderline(bool))); // 创建主布局 QVBoxLayout *layout = new QVBoxLayout; layout->addWidget(toolBar); layout->addWidget(textEdit); window->setLayout(layout); window->show(); return app.exec(); } ``` 在该代码中,我们使用了QFontComboBox、QComboBox和QToolBar控件来实现字体、字体颜色和工具的选择。我们还创建了QTextEdit控件用于文本编辑,并使用QAction控件来实现加粗、斜体和下划线等功能。最后,我们将所有控件加入到一个垂直布局中,并将其设置为主窗口的布局。
评论 4
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值