Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix broken Code Editor launch #2923

Merged
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
2 changes: 1 addition & 1 deletion README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Likewise, the current version of wxPython, is 4.2.2, but RIDE is known to work w

`pip install -U robotframework-ride`

(3.8 <= python <= 3.13) Install current development version (**2.2dev9**) with:
(3.8 <= python <= 3.13) Install current development version (**2.2dev10**) with:

`pip install -U https://github.com/robotframework/RIDE/archive/develop.zip`

Expand Down
2 changes: 1 addition & 1 deletion src/robotide/application/releasenotes.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ def set_content(self, html_win, content):
<pre class="literal-block">python -m robotide.postinstall -install</pre>
<p>or</p>
<pre class="literal-block">ride_postinstall.py -install</pre>
<p>RIDE {VERSION} was released on 20/February/2025.</p>
<p>RIDE {VERSION} was released on 21/February/2025.</p>
<!-- <br/>
<h3>May The Fourth Be With You!</h3>
<h3>Celebrate the bank holiday, 10th June, Day of Portugal, Portuguese Communities and Camões!!</h3>
Expand Down
13 changes: 7 additions & 6 deletions src/robotide/editor/customsourceeditor.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

import wx
import wx.stc as stc
from .pythoneditor import PythonSTC
from robotide.editor.pythoneditor import PythonSTC
from wx import Colour

# ---------------------------------------------------------------------------
Expand All @@ -37,8 +37,8 @@
# ----------------------------------------------------------------------

class SourceCodeEditor(PythonSTC):
def __init__(self, parent, style=wx.BORDER_NONE):
PythonSTC.__init__(self, parent, -1, style=style)
def __init__(self, parent, options, style=wx.BORDER_NONE):
PythonSTC.__init__(self, parent, -1, options, style=style)
self.SetUpEditor()

# Some methods to make it compatible with how the wxTextCtrl is used
Expand Down Expand Up @@ -240,9 +240,9 @@ def __init__(self, parent, main_frame, filepath=None):
self.path = filepath
wx.Panel.__init__(self, parent, size=(1, 1))
self.mainFrame = main_frame
self.editor = SourceCodeEditor(self)
self.editor = SourceCodeEditor(self, options={'tab markers':True, 'fold symbols':2})
self.editor.RegisterModifiedEvent(self.on_code_modified)

parent.SetName(f'Code Editor: {filepath}')
"""
self.SetBackgroundColour(Colour(200, 222, 40))
self.SetOwnBackgroundColour(Colour(200, 222, 40))
Expand Down Expand Up @@ -528,8 +528,9 @@ def get_config():


def main(filepath, frame=None):
__name__ = 'Editor'
__name__ = f'Code Editor: {filepath}'
app = wx.App()
app.SetAppDisplayName(__name__)
if frame is None:
frame = wx.Frame(None)
CodeEditorPanel(frame, None, filepath)
Expand Down
2 changes: 1 addition & 1 deletion src/robotide/editor/pythoneditor.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
class PythonSTC(stc.StyledTextCtrl):

def __init__(self, parent, idd, options: dict, pos=wx.DefaultPosition, size=wx.DefaultSize, style=0):
stc.StyledTextCtrl.__init__(self, parent, idd, pos, size, style)
stc.StyledTextCtrl.__init__(self, parent=parent, id=idd, pos=pos, size=size, style=style)

# self.CmdKeyAssign(ord('B'), stc.STC_SCMOD_CTRL, stc.STC_CMD_ZOOMIN)
# self.CmdKeyAssign(ord('N'), stc.STC_SCMOD_CTRL, stc.STC_CMD_ZOOMOUT)
Expand Down
2 changes: 1 addition & 1 deletion src/robotide/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@
#
# Automatically generated by `tasks.py`.

VERSION = 'v2.2dev9'
VERSION = 'v2.2dev10'