Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions bec_widgets/cli/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -3116,24 +3116,24 @@ def hide_launcher(self):


class LogPanel(RPCBase):
"""Displays a log panel"""
"""Live display of the BEC logs in a table view."""

@rpc_call
def set_plain_text(self, text: str) -> None:
def remove(self):
"""
Set the plain text of the widget.

Args:
text (str): The text to set.
Cleanup the BECConnector
"""

@rpc_call
def set_html_text(self, text: str) -> None:
def attach(self):
"""
None
"""
Set the HTML text of the widget.

Args:
text (str): The text to set.
@rpc_call
def detach(self):
"""
Detach the widget from its parent dock widget (if widget is in the dock), making it a floating widget.
"""


Expand Down
12 changes: 4 additions & 8 deletions bec_widgets/widgets/containers/dock_area/dock_area.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
from bec_widgets.widgets.progress.ring_progress_bar.ring_progress_bar import RingProgressBar
from bec_widgets.widgets.services.bec_queue.bec_queue import BECQueue
from bec_widgets.widgets.services.bec_status_box.bec_status_box import BECStatusBox
from bec_widgets.widgets.utility.logpanel import LogPanel
from bec_widgets.widgets.utility.logpanel.logpanel import LogPanel
from bec_widgets.widgets.utility.visual.dark_mode_button.dark_mode_button import DarkModeButton

logger = bec_logger.logger
Expand Down Expand Up @@ -376,6 +376,7 @@ def _setup_toolbar(self):
"bec_shell": (BECShell.ICON_NAME, "Add BEC Shell", "BECShell"),
"log_panel": (LogPanel.ICON_NAME, "Add LogPanel - Disabled", "LogPanel"),
"sbb_monitor": ("train", "Add SBB Monitor", "SBBMonitor"),
"log_panel": (LogPanel.ICON_NAME, "Add LogPanel", "LogPanel"),
}

# Create expandable menu actions (original behavior)
Expand Down Expand Up @@ -487,9 +488,7 @@ def _connect_menu(menu_key: str):
# first two items not needed for this part
for key, (_, _, widget_type) in mapping.items():
act = menu.actions[key].action
if widget_type == "LogPanel":
act.setEnabled(False) # keep disabled per issue #644
elif key == "terminal":
if key == "terminal":
act.triggered.connect(
lambda _, t=widget_type: self.new(widget=t, closable=True, startup_cmd=None)
)
Expand All @@ -510,10 +509,7 @@ def _connect_flat_actions(mapping: dict[str, tuple[str, str, str]]):
for action_id, (_, _, widget_type) in mapping.items():
flat_action_id = f"flat_{action_id}"
flat_action = self.toolbar.components.get_action(flat_action_id).action
if widget_type == "LogPanel":
flat_action.setEnabled(False) # keep disabled per issue #644
else:
flat_action.triggered.connect(lambda _, t=widget_type: self.new(t))
flat_action.triggered.connect(lambda _, t=widget_type: self.new(t))

_connect_flat_actions(self._ACTION_MAPPINGS["menu_plots"])
_connect_flat_actions(self._ACTION_MAPPINGS["menu_devices"])
Expand Down
58 changes: 0 additions & 58 deletions bec_widgets/widgets/utility/logpanel/_util.py

This file was deleted.

4 changes: 2 additions & 2 deletions bec_widgets/widgets/utility/logpanel/log_panel_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def domXml(self):
return DOM_XML

def group(self):
return "BEC Services"
return ""

def icon(self):
return designer_material_icon(LogPanel.ICON_NAME)
Expand All @@ -51,7 +51,7 @@ def name(self):
return "LogPanel"

def toolTip(self):
return "Displays a log panel"
return "LogPanel"

def whatsThis(self):
return self.toolTip()
Loading
Loading