Merge branch 'tildearrow:master' into guimprove
This commit is contained in:
commit
7a87702518
|
@ -167,7 +167,7 @@ void DivPlatformES5506::acquire(short** buf, size_t len) {
|
||||||
buf[(o<<1)|1][h]=es5506.rout(o);
|
buf[(o<<1)|1][h]=es5506.rout(o);
|
||||||
}
|
}
|
||||||
for (int i=chanMax; i>=0; i--) {
|
for (int i=chanMax; i>=0; i--) {
|
||||||
oscBuf[i]->data[oscBuf[i]->needle++]=(es5506.voice_lout(i)+es5506.voice_rout(i))>>6;
|
oscBuf[i]->data[oscBuf[i]->needle++]=(es5506.voice_lout(i)+es5506.voice_rout(i))>>5;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -203,6 +203,7 @@ const char* aboutLine[]={
|
||||||
"",
|
"",
|
||||||
"greetings to:",
|
"greetings to:",
|
||||||
"NEOART Costa Rica",
|
"NEOART Costa Rica",
|
||||||
|
"Xenium Demoparty",
|
||||||
"all members of Deflers of Noice!",
|
"all members of Deflers of Noice!",
|
||||||
"",
|
"",
|
||||||
"copyright © 2021-2023 tildearrow",
|
"copyright © 2021-2023 tildearrow",
|
||||||
|
|
|
@ -184,6 +184,10 @@ void FurnaceGUI::drawCompatFlags() {
|
||||||
if (ImGui::IsItemHovered()) {
|
if (ImGui::IsItemHovered()) {
|
||||||
ImGui::SetTooltip("behavior changed in 0.6pre5");
|
ImGui::SetTooltip("behavior changed in 0.6pre5");
|
||||||
}
|
}
|
||||||
|
ImGui::Checkbox("Pre-note does not take effects into consideration",&e->song.preNoteNoEffect);
|
||||||
|
if (ImGui::IsItemHovered()) {
|
||||||
|
ImGui::SetTooltip("behavior changed in 0.6pre9");
|
||||||
|
}
|
||||||
ImGui::EndTabItem();
|
ImGui::EndTabItem();
|
||||||
}
|
}
|
||||||
if (ImGui::BeginTabItem(".mod import")) {
|
if (ImGui::BeginTabItem(".mod import")) {
|
||||||
|
|
|
@ -3520,10 +3520,12 @@ bool FurnaceGUI::loop() {
|
||||||
case SDL_DISPLAYEVENT_CONNECTED:
|
case SDL_DISPLAYEVENT_CONNECTED:
|
||||||
logD("display %d connected!",ev.display.display);
|
logD("display %d connected!",ev.display.display);
|
||||||
updateWindow=true;
|
updateWindow=true;
|
||||||
|
shallDetectScale=16;
|
||||||
break;
|
break;
|
||||||
case SDL_DISPLAYEVENT_DISCONNECTED:
|
case SDL_DISPLAYEVENT_DISCONNECTED:
|
||||||
logD("display %d disconnected!",ev.display.display);
|
logD("display %d disconnected!",ev.display.display);
|
||||||
updateWindow=true;
|
updateWindow=true;
|
||||||
|
shallDetectScale=16;
|
||||||
break;
|
break;
|
||||||
case SDL_DISPLAYEVENT_ORIENTATION:
|
case SDL_DISPLAYEVENT_ORIENTATION:
|
||||||
logD("display oriented to %d",ev.display.data1);
|
logD("display oriented to %d",ev.display.data1);
|
||||||
|
@ -6115,6 +6117,14 @@ bool FurnaceGUI::loop() {
|
||||||
willCommit=false;
|
willCommit=false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (shallDetectScale) {
|
||||||
|
if (--shallDetectScale<1) {
|
||||||
|
if (settings.dpiScale<0.5f) {
|
||||||
|
applyUISettings();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (fontsFailed) {
|
if (fontsFailed) {
|
||||||
showError("it appears I couldn't load these fonts. any setting you can check?");
|
showError("it appears I couldn't load these fonts. any setting you can check?");
|
||||||
logE("couldn't load fonts");
|
logE("couldn't load fonts");
|
||||||
|
@ -6889,6 +6899,7 @@ FurnaceGUI::FurnaceGUI():
|
||||||
displayInsTypeListMakeInsSample(-1),
|
displayInsTypeListMakeInsSample(-1),
|
||||||
mobileEditPage(0),
|
mobileEditPage(0),
|
||||||
wheelCalmDown(0),
|
wheelCalmDown(0),
|
||||||
|
shallDetectScale(0),
|
||||||
mobileMenuPos(0.0f),
|
mobileMenuPos(0.0f),
|
||||||
autoButtonSize(0.0f),
|
autoButtonSize(0.0f),
|
||||||
mobileEditAnim(0.0f),
|
mobileEditAnim(0.0f),
|
||||||
|
|
|
@ -1343,6 +1343,7 @@ class FurnaceGUI {
|
||||||
int displayInsTypeListMakeInsSample;
|
int displayInsTypeListMakeInsSample;
|
||||||
int mobileEditPage;
|
int mobileEditPage;
|
||||||
int wheelCalmDown;
|
int wheelCalmDown;
|
||||||
|
int shallDetectScale;
|
||||||
float mobileMenuPos, autoButtonSize, mobileEditAnim;
|
float mobileMenuPos, autoButtonSize, mobileEditAnim;
|
||||||
ImVec2 mobileEditButtonPos, mobileEditButtonSize;
|
ImVec2 mobileEditButtonPos, mobileEditButtonSize;
|
||||||
const int* curSysSection;
|
const int* curSysSection;
|
||||||
|
|
|
@ -29,6 +29,7 @@
|
||||||
#include "IconsFontAwesome4.h"
|
#include "IconsFontAwesome4.h"
|
||||||
#include "furIcons.h"
|
#include "furIcons.h"
|
||||||
#include "misc/cpp/imgui_stdlib.h"
|
#include "misc/cpp/imgui_stdlib.h"
|
||||||
|
#include "scaling.h"
|
||||||
#include <fmt/printf.h>
|
#include <fmt/printf.h>
|
||||||
#include <imgui.h>
|
#include <imgui.h>
|
||||||
|
|
||||||
|
@ -4088,7 +4089,20 @@ void FurnaceGUI::applyUISettings(bool updateFonts) {
|
||||||
setupLabel(settings.emptyLabel.c_str(),emptyLabel,3);
|
setupLabel(settings.emptyLabel.c_str(),emptyLabel,3);
|
||||||
setupLabel(settings.emptyLabel2.c_str(),emptyLabel2,2);
|
setupLabel(settings.emptyLabel2.c_str(),emptyLabel2,2);
|
||||||
|
|
||||||
if (settings.dpiScale>=0.5f) dpiScale=settings.dpiScale;
|
// get scale factor
|
||||||
|
const char* videoBackend=SDL_GetCurrentVideoDriver();
|
||||||
|
if (settings.dpiScale>=0.5f) {
|
||||||
|
logD("setting UI scale factor from config (%f).",settings.dpiScale);
|
||||||
|
dpiScale=settings.dpiScale;
|
||||||
|
} else {
|
||||||
|
logD("auto-detecting UI scale factor.");
|
||||||
|
dpiScale=getScaleFactor(videoBackend);
|
||||||
|
logD("scale factor: %f",dpiScale);
|
||||||
|
if (dpiScale<0.1f) {
|
||||||
|
logW("scale what?");
|
||||||
|
dpiScale=1.0f;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// colors
|
// colors
|
||||||
if (updateFonts) {
|
if (updateFonts) {
|
||||||
|
|
Loading…
Reference in a new issue