Fix GOLDEN_RATIO

Signed-off-by: Loren Eteval <loren.eteval@proton.me>
This commit is contained in:
Loren Eteval
2023-09-15 00:34:49 +08:00
parent aa5cc3b896
commit 082386a188
5 changed files with 8 additions and 9 deletions
+1 -1
View File
@@ -43,7 +43,7 @@ PLATFORM = platform.system()
LOCAL_SERVER_NAME = '891ad49d-8996-43cb-820c-d9baf42a04de'
GOLDEN_RATIO = (math.sqrt(5) - 1) / 2
GOLDEN_RATIO = (math.sqrt(5) + 1) / 2
SYSTEM_LANGUAGE = QtCore.QLocale().name()[:2].upper()
+1 -1
View File
@@ -219,7 +219,7 @@ class AssetViewerWidget(SupportThemeChangedCallback, MainWindow):
self.setWidthAndHeight()
def setWidthAndHeight(self):
self.setGeometry(100, 100, 512 * GOLDEN_RATIO, 512)
self.setGeometry(100, 100, 360, 360 * GOLDEN_RATIO)
moveToCenter(self)
+2 -2
View File
@@ -15,7 +15,7 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
from Furious.Utility.Constants import APPLICATION_NAME, GOLDEN_RATIO, Color
from Furious.Utility.Constants import APPLICATION_NAME, Color
from Furious.Utility.Utility import (
bootstrapIcon,
StateContext,
@@ -33,7 +33,7 @@ class ConnectingProgressBar(Translatable, SupportConnectedCallback, QWidget):
self.setWindowTitle(_(APPLICATION_NAME))
self.setWindowIcon(bootstrapIcon('rocket-takeoff-window.svg'))
self.setFixedSize(280, int(100 * GOLDEN_RATIO))
self.setFixedSize(280, 61)
@QtCore.Slot()
def updateProgressBar():
+3 -4
View File
@@ -41,7 +41,6 @@ from Furious.Utility.Constants import (
APPLICATION_REPO_OWNER_NAME,
APPLICATION_REPO_NAME,
PLATFORM,
GOLDEN_RATIO,
Color,
)
from Furious.Utility.Utility import (
@@ -1767,8 +1766,8 @@ class EditConfigurationWidget(MainWindow):
self.splitter = QSplitter(QtCore.Qt.Orientation.Horizontal)
self.splitter.addWidget(self.serverTab)
self.splitter.addWidget(self.editorTab)
self.splitter.setStretchFactor(0, 1)
self.splitter.setStretchFactor(1, 1)
self.splitter.setStretchFactor(0, 8)
self.splitter.setStretchFactor(1, 5)
self.fakeCentralWidget = QWidget()
@@ -1877,7 +1876,7 @@ class EditConfigurationWidget(MainWindow):
except Exception:
# Any non-exit exceptions
self.setGeometry(100, 100, 1568, 1568 * GOLDEN_RATIO)
self.setGeometry(100, 100, 1800, 960)
moveToCenter(self)
+1 -1
View File
@@ -1275,7 +1275,7 @@ class EditRoutingWidget(MainWindow):
except Exception:
# Any non-exit exceptions
self.setGeometry(100, 100, 640, 640 * GOLDEN_RATIO)
self.setGeometry(100, 100, 360 * GOLDEN_RATIO, 360)
moveToCenter(self)