# Copyright (c) 2025, UChicago Argonne, LLC
# BSD OPEN SOURCE LICENSE. Full license can be found in LICENSE
# Copyright (c) 2025, UChicago Argonne, LLC
# BSD OPEN SOURCE LICENSE. Full license can be found in LICENSE
from os.path import join, dirname
from .renames_icon_path import adjusts_icon_paths


def load_style_by_name(layer, style_name: str) -> None:
    adjusts_icon_paths()
    fldr = join(dirname(__file__), "styles")
    layer.loadNamedStyle(join(fldr, style_name), True)
