Bug report #21880
Style file (QML) can't be used to add styles to rasters
|Affected QGIS version:||3.6.1||Regression?:||No|
|Operating System:||Windows 10||Easy fix?:||Yes|
|Pull Request or Patch supplied:||No||Resolution:||duplicate|
|Crashes QGIS or corrupts data:||No||Copied to github as #:||29695|
When styling raster files using QML file through 'Load style' button in Symbology panel, after clicking OK or Apply button, a default style gets applied and QML file is discarded.
Loading Style from QML file
After clicking the apply button
The only work around is to rename the style file to the same name as raster and place it in same folder. Still if you click ok or Apply button in symbology panel, the style changes to a default one.