Fix #153 - Allow users to specifically import 99%,99.6%, 0.4%,1% and 2% annual design days#791
Fix #153 - Allow users to specifically import 99%,99.6%, 0.4%,1% and 2% annual design days#791
Conversation
|
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅ |
|
Thanks @antonszilasi! I think the first thing to do is to create a mockup of the UI that we want to make, the unmethours post suggested this from Trace: Once we have the mockup, we can create the widget to match it. |
|
Marking the PR as non-draft because I want a CI run on it. @antonszilasi I fixed up the clang format and the cppcheck thingy quickly. |
|
I started a test bed here in case it's useful: https://godbolt.org/z/rxern817h |
|
I have read the CLA Document and I hereby sign the CLA |
3e269fe to
a5263ba
Compare
| { | ||
| return false; | ||
| } | ||
|
|
|
Importing ddy which is missing 0.4% design days |
I think your interface is nice as is @macumber. I was originally thinking we've do something fancier/more explicitly per this link I started, but I don't know if it's worth overdoing it. std::vector<std::string> heatingPercentages = {"99.6%", "99%"};
std::vector<std::string> coolingPercentages = {"2%", "1%", ".4%"};
std::vector<DesignDayInfo> designDayTypes = {
// Heating
{.day_type = DesignDayInfo::DayType::Heating, .lookup_string = "DB", .name = "Heating", .tooltip = "Sizing heating equipment"},
{.day_type = DesignDayInfo::DayType::Heating, .lookup_string = "WS=>MCDB", .name = "Heating Windy", .tooltip = "Used for sizing based on infiltration"},
{.day_type = DesignDayInfo::DayType::Heating, .lookup_string = "DP=>MCDB", .name = "Heating Humid", .tooltip = "Used for sizing dehumidification systems"},
// Cooling
{.day_type = DesignDayInfo::DayType::Cooling, .lookup_string = "DB=>MWB", .name = "Cooling", .tooltip = "Sizing Chillers or air-conditioning units"},
{.day_type = DesignDayInfo::DayType::Cooling, .lookup_string = "WB=>MDB", .name = "Cooling Latent", .tooltip = "Used to size cooling towers, evap-coolers, and fresh-air ventilation systems"},
{.day_type = DesignDayInfo::DayType::Cooling, .lookup_string = "DP=>MDB", .name = "Cooling Dehum", .tooltip = "Used for sizing dehumidification systems"},
{.day_type = DesignDayInfo::DayType::Cooling, .lookup_string = "Enth=>MDB", .name = "Cooling Enthalpy", .tooltip = "Used for sizing based on infiltration and/or ventilation"},
};It would look kinda like your mockup but with extra rows for the cooling ones and tooltips |
There was a problem hiding this comment.
Pull Request Overview
This PR aims to address issue 153 by allowing users to selectively import design days with specific percentages (99%, 99.6%, 0.4%, 1%, and 2%) to better refine annual design day selections.
- Added grid cell selection signal emissions in OSObjectSelector.
- Introduced style updating and header/visibility properties in OSCellWrapper.
- Implemented a dialog in LocationTabView for selecting design days and updated associated test cases.
Reviewed Changes
Copilot reviewed 11 out of 23 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/shared_gui_components/OSObjectSelector.cpp | Emits grid row selection changes after updating cell info. |
| src/shared_gui_components/OSCellWrapper.hpp & OSCellWrapper.cpp | Adds updateStyle functionality and new member variables to control style. |
| src/openstudio_lib/LocationTabView.hpp & LocationTabView.cpp | Introduces design day selection dialog, SortableDesignDay helper, and modifies design day insertion/removal logic. |
| src/openstudio_lib/test/LocationTab_GTest.cpp | Updates test cases for SortableDesignDay behavior. |
| .github/workflows/app_build.yml | Updates Conan install flags for improved compatibility with recent Clang. |
Files not reviewed (12)
- src/openstudio_lib/CMakeLists.txt: Language not supported
- translations/OpenStudioApp_ar.ts: Language not supported
- translations/OpenStudioApp_ca.ts: Language not supported
- translations/OpenStudioApp_de.ts: Language not supported
- translations/OpenStudioApp_el.ts: Language not supported
- translations/OpenStudioApp_es.ts: Language not supported
- translations/OpenStudioApp_fa.ts: Language not supported
- translations/OpenStudioApp_fr.ts: Language not supported
- translations/OpenStudioApp_he.ts: Language not supported
- translations/OpenStudioApp_hi.ts: Language not supported
- translations/OpenStudioApp_it.ts: Language not supported
- translations/OpenStudioApp_ja.ts: Language not supported
Comments suppressed due to low confidence (1)
src/shared_gui_components/OSCellWrapper.cpp:585
- [nitpick] Consider adding inline comments to clarify the bit ordering in the 'style' bitset to help future maintainers understand how the style string is constructed.
std::bitset<2> style;
…levels, add a gtest
… instead, attempt to fix the Mac CI issue. Really want NatLabRockies/OpenStudio#5229 to be fixed as the root cause
…objects are deleted
/opt/Qt/6.5.2/gcc_64/bin/lupdate -project /media/DataExt4/Software/Others/OSApp-build-release/translations/.lupdate/translations_interface_project.json -no-obsolete
|
@antonszilasi Thanks for this work, this is going to be a nice improvement for everyone! I made a couple of changes, if @antonszilasi and/or @macumber could glance them over that'd be great. Then merge away! |
|
Changes look great @jmarrec, thanks for updating the languages |










WIP to address issue 153 and sketching out some ideas