Przeglądaj źródła

Merge branch 'master' of https://git.yishihui.com/iOS/BFRecordScreenKit

wenweiwei 3 lat temu
rodzic
commit
ce2d561bbc

+ 2 - 1
BFRecordScreenKit/Classes/RecordScreen/Controller/BFRecordScreenController.swift

@@ -535,7 +535,7 @@ public class BFRecordScreenController: BFBaseViewController {
             }
         }
         if findShowSubtitle != nil, subtitleSettingView.subtitle.setting.subtitleIsShow {
-            subtitleLabel.text = findShowSubtitle?.text
+            subtitleLabel.text = findShowSubtitle?.text ?? ""
             setSubtitleStyle(settingModel: subtitleSettingView.subtitle.setting)
 
         } else {
@@ -557,6 +557,7 @@ public class BFRecordScreenController: BFBaseViewController {
 
             let height = sizeTextFits(attributedText: nil, text: subtitleLabel.text ?? "", numberOfLines: 0, font: subtitleLabel.font, maxSize: CGSize(width: cScreenWidth - leftPoint * 2, height: CGFloat.greatestFiniteMagnitude)).height
 
+            subtitleLabel.backgroundColor = subtitleSettingView.subtitle.setting.backgroundColor
             // 下 //设置位置
             if subtitleSettingView.subtitle.setting.subtitlePoint == 0 {
                 subtitleLabel.frame = CGRect(x: leftPoint, y: cScreenHeigth * 0.70 - height, width: cScreenWidth - 37 * 2, height: height)

+ 1 - 1
BFRecordScreenKit/Classes/RecordScreen/View/BFSubtitleEditView.swift

@@ -29,7 +29,7 @@ class BFSubtitleEditView: UIView {
         textView.maxTextLengthRemind = ""
         textView.backgroundColor = UIColor.clear
         textView.textColor = UIColor.hexColor(hexadecimal: "#FFFFFF")
-        textView.tintColor = UIColor.hexColor(hexadecimal: "#EE0051")
+        textView.tintColor = UIColor.hexColor(hexadecimal: "#28BE67")
         textView.font = UIFont.systemFont(ofSize: 17)
         textView.placeHolder = ""
         textView.placeHolderColor = UIColor.hexColor(hexadecimal: "#555555")

+ 3 - 2
BFRecordScreenKit/Classes/RecordScreen/View/BFSubtitleSettingView.swift

@@ -9,6 +9,7 @@ import BFCommonKit
 import BFMediaKit
 import BFUIKit
 import Foundation
+import UIKit
 
 typealias SubtitleSettingCallBack = (_ subtitileModel: PQEditSubTitleModel) -> Void
 
@@ -57,7 +58,7 @@ class BFSubtitleSettingView: UIView {
                        3: ["fontColor": UIColor.hexColor(hexadecimal: "#80E4AB"), "backgroundColor": UIColor.clear, "strokeColor": UIColor.black, "backgroundAlpha": 0.0],
                        4: ["fontColor": UIColor.hexColor(hexadecimal: "#FFFFFF"), "backgroundColor": UIColor.clear, "strokeColor": UIColor.black, "backgroundAlpha": 0.0],
                        5: ["fontColor": UIColor.hexColor(hexadecimal: "#000000"), "backgroundColor": UIColor.clear, "strokeColor": UIColor.white, "backgroundAlpha": 0.0],
-                       6: ["fontColor": UIColor.hexColor(hexadecimal: "#FFFFFF"), "backgroundColor": UIColor.black, "strokeColor": UIColor.black, "backgroundAlpha": 0.6]]
+                       6: ["fontColor": UIColor.hexColor(hexadecimal: "#FFFFFF"), "backgroundColor":UIColor.init(red: 0, green: 0, blue: 0, alpha: 0.6), "strokeColor": UIColor.clear, "backgroundAlpha": 0.6]]
 
         // 字体样式
         for i in 0...6 {
@@ -170,7 +171,7 @@ class BFSubtitleSettingView: UIView {
         disabelTitle.textAlignment = .left
         disabelTitle.font = UIFont.boldSystemFont(ofSize: 17)
         disabelTitle.textColor = .white
-        disabelTitle.text = "不显示字幕"
+        disabelTitle.text = "关闭字幕"
         backView.addSubview(disabelTitle)
         disabelTitle.snp.makeConstraints { make in
             make.width.equalTo(100)