diff --git a/CMakeLists.txt b/CMakeLists.txt index 7f4a01c2a..deff109d2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -10,7 +10,7 @@ set(CMAKE_CXX_STANDARD 14) set(CMAKE_PROJECT_VERSION_MAJOR 0) set(CMAKE_PROJECT_VERSION_MINOR 5) -set(CMAKE_PROJECT_VERSION_PATCH 1) +set(CMAKE_PROJECT_VERSION_PATCH 2) if (ANDROID) set(BUILD_GUI_DEFAULT OFF) diff --git a/res/Info.plist b/res/Info.plist index 9b31261e6..c75264efc 100644 --- a/res/Info.plist +++ b/res/Info.plist @@ -15,17 +15,17 @@ CFBundleInfoDictionaryVersion 6.0 CFBundleLongVersionString - 0.5.1 + 0.5.2 CFBundleName Furnace CFBundlePackageType APPL CFBundleShortVersionString - 0.5.1 + 0.5.2 CFBundleSignature ???? CFBundleVersion - 0.5.1 + 0.5.2 NSHumanReadableCopyright NSHighResolutionCapable diff --git a/src/engine/engine.h b/src/engine/engine.h index ef82465a1..4c5cdba4b 100644 --- a/src/engine/engine.h +++ b/src/engine/engine.h @@ -11,8 +11,8 @@ #include #include -#define DIV_VERSION "0.5.2pre3" -#define DIV_ENGINE_VERSION 39 +#define DIV_VERSION "0.5.2" +#define DIV_ENGINE_VERSION 40 enum DivStatusView { DIV_STATUS_NOTHING=0, diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index 5481a0768..daa5c8572 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -2624,10 +2624,27 @@ void FurnaceGUI::drawPattern() { for (int i=0; isong.chanShow[i]) continue; ImGui::TableNextColumn(); + bool displayTooltip=false; if (e->song.chanCollapse[i]) { - snprintf(chanID,256,"%s##_CH%d",e->getChannelShortName(i),i); + const char* chName=e->getChannelShortName(i); + if (strlen(chName)>3) { + snprintf(chanID,256,"...##_CH%d",i); + } else { + snprintf(chanID,256,"%s##_CH%d",chName,i); + } + displayTooltip=true; } else { - snprintf(chanID,256," %s##_CH%d",e->getChannelName(i),i); + const char* chName=e->getChannelName(i); + size_t chNameLimit=6+4*e->song.pat[i].effectRows; + if (strlen(chName)>chNameLimit) { + String shortChName=chName; + shortChName.resize(chNameLimit-3); + shortChName+="..."; + snprintf(chanID,256," %s##_CH%d",shortChName.c_str(),i); + displayTooltip=true; + } else { + snprintf(chanID,256," %s##_CH%d",chName,i); + } } bool muted=e->isChannelMuted(i); ImVec4 chanHead=muted?uiColors[GUI_COLOR_CHANNEL_MUTED]:uiColors[GUI_COLOR_CHANNEL_FM+e->getChannelType(i)]; @@ -2643,6 +2660,9 @@ void FurnaceGUI::drawPattern() { ImGui::TableSetBgColor(ImGuiTableBgTarget_CellBg,ImGui::GetColorU32(chanHead)); if (muted) ImGui::PushStyleColor(ImGuiCol_Text,uiColors[GUI_COLOR_CHANNEL_MUTED]); ImGui::Selectable(chanID,true,ImGuiSelectableFlags_NoPadWithHalfSpacing,ImVec2(0.0f,lineHeight+1.0f*dpiScale)); + if (displayTooltip && ImGui::IsItemHovered()) { + ImGui::SetTooltip("%s",e->getChannelName(i)); + } if (ImGui::IsItemClicked(ImGuiMouseButton_Left)) { if (settings.soloAction!=1 && soloTimeout>0 && soloChan==i) { e->toggleSolo(i); @@ -5780,24 +5800,27 @@ bool FurnaceGUI::loop() { ImGui::EndMenu(); } if (ImGui::BeginMenu("window")) { - if (ImGui::MenuItem("play/edit controls")) editControlsOpen=!editControlsOpen; - if (ImGui::MenuItem("song information")) songInfoOpen=!songInfoOpen; - if (ImGui::MenuItem("instruments")) insListOpen=!insListOpen; - if (ImGui::MenuItem("instrument editor")) insEditOpen=!insEditOpen; - if (ImGui::MenuItem("wavetables")) waveListOpen=!waveListOpen; - if (ImGui::MenuItem("wavetable editor")) waveEditOpen=!waveEditOpen; - if (ImGui::MenuItem("samples")) sampleListOpen=!sampleListOpen; - if (ImGui::MenuItem("sample editor")) sampleEditOpen=!sampleEditOpen; - if (ImGui::MenuItem("orders")) ordersOpen=!ordersOpen; - if (ImGui::MenuItem("pattern")) patternOpen=!patternOpen; - if (ImGui::MenuItem("mixer")) mixerOpen=!mixerOpen; - if (ImGui::MenuItem("oscilloscope")) oscOpen=!oscOpen; - if (ImGui::MenuItem("volume meter")) volMeterOpen=!volMeterOpen; - if (ImGui::MenuItem("statistics")) statsOpen=!statsOpen; - if (ImGui::MenuItem("channels")) channelsOpen=!channelsOpen; - if (ImGui::MenuItem("compatibility flags")) compatFlagsOpen=!compatFlagsOpen; - if (ImGui::MenuItem("piano/input pad")) pianoOpen=!pianoOpen; - if (ImGui::MenuItem("song comments")) notesOpen=!notesOpen; + if (ImGui::MenuItem("song information",NULL,songInfoOpen)) songInfoOpen=!songInfoOpen; + if (ImGui::MenuItem("instruments",NULL,insListOpen)) insListOpen=!insListOpen; + if (ImGui::MenuItem("wavetables",NULL,waveListOpen)) waveListOpen=!waveListOpen; + if (ImGui::MenuItem("samples",NULL,sampleListOpen)) sampleListOpen=!sampleListOpen; + if (ImGui::MenuItem("orders",NULL,ordersOpen)) ordersOpen=!ordersOpen; + if (ImGui::MenuItem("pattern",NULL,patternOpen)) patternOpen=!patternOpen; + if (ImGui::MenuItem("mixer",NULL,mixerOpen)) mixerOpen=!mixerOpen; + if (ImGui::MenuItem("channels",NULL,channelsOpen)) channelsOpen=!channelsOpen; + if (ImGui::MenuItem("compatibility flags",NULL,compatFlagsOpen)) compatFlagsOpen=!compatFlagsOpen; + if (ImGui::MenuItem("song comments",NULL,notesOpen)) notesOpen=!notesOpen; + ImGui::Separator(); + if (ImGui::MenuItem("instrument editor",NULL,insEditOpen)) insEditOpen=!insEditOpen; + if (ImGui::MenuItem("wavetable editor",NULL,waveEditOpen)) waveEditOpen=!waveEditOpen; + if (ImGui::MenuItem("sample editor",NULL,sampleEditOpen)) sampleEditOpen=!sampleEditOpen; + ImGui::Separator(); + if (ImGui::MenuItem("play/edit controls",NULL,editControlsOpen)) editControlsOpen=!editControlsOpen; + if (ImGui::MenuItem("piano/input pad",NULL,pianoOpen)) pianoOpen=!pianoOpen; + if (ImGui::MenuItem("oscilloscope",NULL,oscOpen)) oscOpen=!oscOpen; + if (ImGui::MenuItem("volume meter",NULL,volMeterOpen)) volMeterOpen=!volMeterOpen; + if (ImGui::MenuItem("statistics",NULL,statsOpen)) statsOpen=!statsOpen; + ImGui::EndMenu(); } if (ImGui::BeginMenu("help")) {