mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 14:02:21 -04:00
Adjust HTML editor / add-on config editor font (#3054)
* Reduce font size of add-on config editor * Change HTML editor font to Consolas * Remove unused form
This commit is contained in:
parent
55dacf05c3
commit
3d184073d7
5 changed files with 2 additions and 86 deletions
|
@ -1585,7 +1585,7 @@ class ConfigEditor(QDialog):
|
|||
font_mono = QFont("Consolas")
|
||||
if not font_mono.exactMatch():
|
||||
font_mono = QFontDatabase.systemFont(QFontDatabase.SystemFont.FixedFont)
|
||||
font_mono.setPointSize(font_mono.pointSize() + 1)
|
||||
font_mono.setPointSize(font_mono.pointSize())
|
||||
self.form.editor.setFont(font_mono)
|
||||
|
||||
def updateHelp(self) -> None:
|
||||
|
|
|
@ -14,7 +14,6 @@ from . import (
|
|||
customstudy,
|
||||
dconf,
|
||||
debug,
|
||||
editaddon,
|
||||
editcurrent,
|
||||
edithtml,
|
||||
emptycards,
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
from typing import TYPE_CHECKING
|
||||
|
||||
from aqt.qt import qtmajor
|
||||
|
||||
if qtmajor > 5 or TYPE_CHECKING:
|
||||
from _aqt.forms.editaddon_qt6 import *
|
||||
else:
|
||||
from _aqt.forms.editaddon_qt5 import * # type: ignore
|
|
@ -1,76 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>Dialog</class>
|
||||
<widget class="QDialog" name="Dialog">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>753</width>
|
||||
<height>475</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string notr="true">Dialog</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QPlainTextEdit" name="text">
|
||||
<property name="font">
|
||||
<font>
|
||||
<family>Courier 10 Pitch</family>
|
||||
</font>
|
||||
</property>
|
||||
<property name="plainText">
|
||||
<string/>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QDialogButtonBox" name="buttonBox">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="standardButtons">
|
||||
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Save</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources/>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>accepted()</signal>
|
||||
<receiver>Dialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>248</x>
|
||||
<y>254</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>157</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>rejected()</signal>
|
||||
<receiver>Dialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>316</x>
|
||||
<y>260</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>286</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|
|
@ -103,6 +103,7 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html
|
|||
|
||||
:global(.CodeMirror) {
|
||||
height: auto;
|
||||
font-family: Consolas monospace;
|
||||
}
|
||||
|
||||
:global(.CodeMirror-wrap pre) {
|
||||
|
|
Loading…
Reference in a new issue