diff --git a/LunaTranslator/LunaTranslator/gui/textbrowser.py b/LunaTranslator/LunaTranslator/gui/textbrowser.py index 2e07e4eb..9673d503 100644 --- a/LunaTranslator/LunaTranslator/gui/textbrowser.py +++ b/LunaTranslator/LunaTranslator/gui/textbrowser.py @@ -266,7 +266,14 @@ class Textbrowser: self.movep(0, self.savey) if globalconfig["zitiyangshi"] == 3: + self.textbrowser.show() + self.textbrowserback.show() self.showyinyingtext(color, b1, b2) + self.textbrowser.hide() + self.textbrowserback.hide() + else: + self.textbrowser.show() + self.textbrowserback.show() def getcurrpointer(self): return self.textcursor.position() diff --git a/LunaTranslator/LunaTranslator/gui/translatorUI.py b/LunaTranslator/LunaTranslator/gui/translatorUI.py index 92f8dfc2..50770a50 100644 --- a/LunaTranslator/LunaTranslator/gui/translatorUI.py +++ b/LunaTranslator/LunaTranslator/gui/translatorUI.py @@ -872,7 +872,14 @@ class QUnFrameWindow(resizableframeless): return newHeight = self.document.size().height() width = self.width() - self.resize(width, int(5 + newHeight + globalconfig["buttonsize"] * 1.5)) + self.resize( + width, + int( + max(0, -globalconfig["extra_space"]) + + newHeight + + globalconfig["buttonsize"] * 1.5 + ), + ) def clickRange(self, auto): if globalconfig["sourcestatus2"]["ocr"]["use"] == False: