From 8720847f547f9b8cff965569828b60f2efc515e4 Mon Sep 17 00:00:00 2001 From: True Zhuanjia Date: Mon, 19 Aug 2024 00:32:21 +0800 Subject: [PATCH] build 27, adjust font size for onscreen key label --- Limelight/Input/OnScreenKeyboardButtonView.swift | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Limelight/Input/OnScreenKeyboardButtonView.swift b/Limelight/Input/OnScreenKeyboardButtonView.swift index ab3c2573..8e338398 100644 --- a/Limelight/Input/OnScreenKeyboardButtonView.swift +++ b/Limelight/Input/OnScreenKeyboardButtonView.swift @@ -47,7 +47,7 @@ import UIKit private func setupView() { label.text = self.keyLabel - //label.font = UIFont.systemFont(ofSize: 28) + label.font = UIFont.systemFont(ofSize: 19) label.translatesAutoresizingMaskIntoConstraints = false label.adjustsFontSizeToFitWidth = true label.minimumScaleFactor = 0.1 // Adjust the scale factor as needed @@ -78,8 +78,8 @@ import UIKit ]) NSLayoutConstraint.activate([ - label.leadingAnchor.constraint(equalTo: self.leadingAnchor, constant: 5), - label.trailingAnchor.constraint(equalTo: self.trailingAnchor, constant: -5), + label.leadingAnchor.constraint(equalTo: self.leadingAnchor, constant: 10), // set up label size contrain within UIView + label.trailingAnchor.constraint(equalTo: self.trailingAnchor, constant: -10), label.centerXAnchor.constraint(equalTo: centerXAnchor), label.centerYAnchor.constraint(equalTo: centerYAnchor), //label.heightAnchor.constraint(equalToConstant: 40)