code: def update_state(self, iid, state):
          
          if state not in ["normal", "hover", "active"]:
              raise ValueError("Invalid state: {}".format(state))
          marker = self._markers[iid]
          rectangle_id, text_id = marker["rectangle_id"], marker["text_id"]
          state = "" if state == "normal" else state + "_"
          colors = {}
          for color_type in ["background", "foreground", "outline", "border"]:
              value = marker[state + color_type]
              attribute = "_marker_{}".format(color_type)
              colors[color_type] = getattr(self, attribute) if value == "default" else value
          self._timeline.itemconfigure(rectangle_id, fill=colors["background"], width=colors["border"],
                                       outline=colors["outline"])
          self._timeline.itemconfigure(text_id, fill=colors["foreground"])
docs: Set a custom state of the marker
  
          :param iid: identifier of the marker to set the state of
          :type iid: str
          :param state: supports "active", "hover", "normal"
          :type state: str