Commit Graph
4 Commits
Author SHA1 Message Date
Kristian Bendiksen d87a0d3048 Refactor RifFormationNamesReader to return std::expected
Replace the QString* errorMessage out-parameter with std::expected<RigFormationNames, QString> in RifFormationNamesReader, and propagate the pattern to RimFormationNames::readFormationNamesFile() which now returns std::expected<void, QString>.

Fatal errors (file cannot be opened, FMU line-parse failure) return std::unexpected. Malformed .lyr lines are still skipped so the rest of the file loads, with warnings logged via RiaLogging instead of collected in the out-parameter. RimFormationNamesCollection::readAllFormationNames() now logs errors it previously discarded.
2026-08-05 16:03:42 +02:00
Kristian Bendiksen bb0afbf962 #13126 RiaLogging: Extract errorInMessageBox to RiuMessageDialog
Move the QMessageBox-displaying helper out of the logging utility into a
dedicated UI class. RiaLogging.h no longer pulls QMessageBox/QWidget into
the ~270 files that include it. Behavior is preserved: showError displays
the dialog when running interactively (and not under regression tests),
then forwards the text to RiaLogging::error.
2026-05-08 10:11:09 +02:00
Magne Sjaastad 1cd3cf3b67 Fix zone colors to honor LYR-file specification (#13658)
* #12974 Fix zone colors to honor LYR-file specification

- Map formation colors by name instead of palette index in updateFormationNamesOnPlot()
- Map formation colors by categoryValue lookup in updateCellResultLegend(), fixing
  incorrect colors when showOnlyVisibleCategoriesInLegend filters the active set
- Add RimColorLegendCollection::createColorLegendFromFormationNames() and call it
  from readAllFormationNames() so LYR colors are available after project load
- Auto-assign formation color legend when a formation case is set on a well log track
- Rename fileNameWoPath() to shortName() and switch to baseName() (no extension)
- Remove addCustomColorLegend() from RicImportFormationNamesFeature; logic now lives
  in RimColorLegendCollection
- Set formation legend when creating new Well Log Extraction Curve track
2026-02-25 18:16:03 +01:00
jonjenssen cbab1b256f Support filtering by formation/polygon when calculating statistics (#12086)
* Support loading formation names when importing an ensemble
* Enable support for formation filtering when calculating contour map
* Add option to limit calculation area to a selection of polygons
2025-01-29 01:36:29 +01:00