修复部分控件在深色模式下颜色异常的问题 (#4899)

This commit is contained in:
Glavo
2025-12-02 20:29:46 +08:00
committed by GitHub
parent 75292d2a52
commit a1e75e48da
15 changed files with 171 additions and 86 deletions

View File

@@ -17,8 +17,6 @@
*/
package org.jackhuang.hmcl.util;
import javafx.scene.paint.Color;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
@@ -27,30 +25,24 @@ import java.util.regex.Pattern;
* @author huangyuhui
*/
public enum Log4jLevel {
FATAL(1, Color.web("#F7A699")),
ERROR(2, Color.web("#FFCCBB")),
WARN(3, Color.web("#FFEECC")),
INFO(4, Color.web("#FBFBFB")),
DEBUG(5, Color.web("#EEE9E0")),
TRACE(6, Color.BLUE),
ALL(2147483647, Color.BLACK);
FATAL(1),
ERROR(2),
WARN(3),
INFO(4),
DEBUG(5),
TRACE(6),
ALL(2147483647);
private final int level;
private final Color color;
Log4jLevel(int level, Color color) {
Log4jLevel(int level) {
this.level = level;
this.color = color;
}
public int getLevel() {
return level;
}
public Color getColor() {
return color;
}
public boolean lessOrEqual(Log4jLevel level) {
return this.level <= level.level;
}