Need preference to disable more new windows in jEdit

In this forum we discuss the future of Ren'Py, both bug fixes and longer-term development. Pre-releases are announced and discussed here.
Post Reply
Message
Author
duanemoody
Regular
Posts: 100
Joined: Fri Oct 02, 2009 2:32 pm
Projects: American Jurassic
Organization: Pier 7 Media
Location: Arizona
Contact:

Need preference to disable more new windows in jEdit

#1 Post by duanemoody »

Create a preference under Launcher Options:Text editor for letting the developer choose whether config.editor_transient passes -reuseview or -newplainview to jEdit (and yes, I understand this is currently the only difference between config.editor and config.editor_transient).

When I'm debugging, I don't actually find my desktop being littered with identical windows helpful, but if it serves a purpose let the developer choose.

This is currently my largest annoyance during development. If I knew how Ren'Py manages its own preferences I would have replaced the argument with a variable and patched opts.rpy myself by now.

As it is, I'm hacking jEdit.Editor.py as follows:

Code: Select all

# Name: jEdit
# Version: 1
# Description: jEdit requires Java be installed on your computer.

import os
import os.path
import sys

editor = os.path.normpath(base + "/../jedit/jedit.jar")
editor = renpy.shell_escape(editor)
editor_exec = 'javaw.exe' if (sys.platform == 'win32') else 'java'

config.editor = editor_exec + ' -jar "' + editor + '" -reuseview "%(filename)s" +line:%(line)d "%(otherfiles)s"'
#config.editor_transient = editor_exec + ' -ar "' + editor + '" -newplainview "%(filename)s" +line:%(line)d "%(otherfiles)s"'
config.editor_transient = config.editor

User avatar
PyTom
Ren'Py Creator
Posts: 16093
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Need preference to disable more new windows in jEdit

#2 Post by PyTom »

Editing the editor.py file is the right way to make editor-specific changes like this.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

Post Reply

Who is online

Users browsing this forum: No registered users