CodeEditor Suggestions

Forum for suggestions and new feature requests for SDStudio Design Environment
User avatar
Louise
Registered User
Posts: 15
Joined: Thu Dec 14, 2017 4:53 pm
Location: SDS-LUA-PB

CodeEditor Suggestions

Post by Louise »

Hi dear Serkan,

For Code Editor,

1- (function Browser)
I want a tool to displays a list of all functions declared in the current EditorTab. This is very simple, just a listBox will need to display the name of the defined functions and with click on the name of any function , In the editor refer to the selected function.

2-(Format indentation)
Ability to reformats the indentation of the selected lines to align with the code above them and to reflect the keywords that they contain. This feature is fantastic.

3-(AutoComplete)
Ability to shows a list of possible items that can be included with the possible matches in the AutoComplete list. (Functions,Var and ....)
User avatar
Serkan
Developer
Developer
Posts: 216
Joined: Thu Jul 04, 2013 8:44 pm
Location: Windows.h
Contact:

Post by Serkan »

Hi
1- (function Browser)
You know that these kind of tools are event based , so declaration of a user function will be available only if that event occurs
Normally there is one (recomended) place to define user functions and it is Global Functions

Currently there is no limitation for users to define their functions in certain location
If you define a function in a buttons OnClick event then that function will be available only after that button is clicked

A function list can be shown for the SDStudio functions , a listbox can show used SDStudio functions in the current script and
if you double click an item then you will be navigated to line where that function was used
2-(Format indentation)
Can you please elaborate this a little bit more

Currently as a standard editor feature ,you can make a vertical selection with ALT+SHIFT key combination and then pressing TAB key
3-(AutoComplete)
This is already exist , an improved version will be added later.
User avatar
abood1987
Registered User
Posts: 69
Joined: Sat Jun 15, 2013 3:03 pm
Location: Egypt مصر أم الدنيا
Contact:

Post by abood1987 »

Nice if I can change the background of the line numbers and Nice to see Annotations 4 error and Nice if i Can Change the Marker background
User avatar
Serkan
Developer
Developer
Posts: 216
Joined: Thu Jul 04, 2013 8:44 pm
Location: Windows.h
Contact:

Post by Serkan »

abood1987 wrote: Sat Dec 16, 2017 9:28 pm Nice if I can change the background of the line numbers and Nice to see Annotations 4 error and Nice if i Can Change the Marker background

All of them are already exist in the SDStudio
SDStudio uses a theme file for script editor appearance ,currently there are 22 editor themes ,
An editor theme outomatically selected according to current application theme (dark ,light,blue etc..)

Currently there is no visual theme editor

An editor theme is an XML file and can easily be modified by any text editor

Here is a theme file that SDStudio uses
SDStudio Blue.zip
(915 Bytes) Downloaded 229 times
User avatar
Louise
Registered User
Posts: 15
Joined: Thu Dec 14, 2017 4:53 pm
Location: SDS-LUA-PB

Post by Louise »

2-(Format indentation)
Can you please elaborate this a little bit more
Currently as a standard editor feature ,you can make a vertical selection with ALT+SHIFT key combination and then pressing TAB key
if you use PureBasic Language Understand what I mean. This feature is available in the PB editor menu.
User avatar
Serkan
Developer
Developer
Posts: 216
Joined: Thu Jul 04, 2013 8:44 pm
Location: Windows.h
Contact:

Post by Serkan »

Louise wrote: Sun Dec 17, 2017 6:48 pm if you use PureBasic Language Understand what I mean. This feature is available in the PB editor menu.
Sorry ,i do not use PureBasic , and have no chance to try it out
Do you mean prettify the selected code ,with new line and tab characters

From :

Code: Select all

if(x == y)then j = 123 end
if (a == a) then d = 123 end
To :

Code: Select all

if (x == y) then 
    j = 123;
end
if (a == a) then
    d = 123; 
end
User avatar
Louise
Registered User
Posts: 15
Joined: Thu Dec 14, 2017 4:53 pm
Location: SDS-LUA-PB

Post by Louise »

Yes Somewhat.
If the code is written in a single line it does not need to be changed. Perhaps the programmer himself tends to.

only all selected lines are aligned to a standard format.

for Example :
from:

Code: Select all

for k = 0, 10000 do
w = "" 
for t = 0, 200 do
w = w.. "ps"
end
end
or

Code: Select all

for k = 0, 10000 do
                     w = "" 
        for t = 0, 200 do
    w = w.. "ps"
                        end
end
To:

Code: Select all

for k = 0, 10000 do
  w = "" 
  for t = 0, 200 do
    w = w.. "ps"
  end
end
User avatar
Serkan
Developer
Developer
Posts: 216
Joined: Thu Jul 04, 2013 8:44 pm
Location: Windows.h
Contact:

Post by Serkan »

OK
It is added to TODO list
Thanks for your suggestions
User avatar
Louise
Registered User
Posts: 15
Joined: Thu Dec 14, 2017 4:53 pm
Location: SDS-LUA-PB

Post by Louise »

Thanks serkan,

Another idea :

Ability to Highlighting of repeated occurrences of the currently selected word in the Editor.


For Example:

font = Dialog.ChooseFont();

msg = "selected font : \r\n"
msg = msg.. "State = ".. font.State .."\r\n"
msg = msg.. "Color = ".. tostring(font.Color) .."\r\n"
msg = msg.. "Name = ".. tostring(font.Name) .."\r\n"
msg = msg.. "Size = ".. tostring(font.Size) .."\r\n"
msg = msg.. "Italic = ".. tostring(font.Italic) .."\r\n"
msg = msg.. "Underline = ".. tostring(font.Underline) .."\r\n"
msg = msg.. "StrikeOut = ".. tostring(font.StrikeOut) .."\r\n"
msg = msg.. "Bold = ".. tostring(font.Bold)

Debug.Value(msg); << ---- my Selected Word
Debug.Show();
User avatar
Serkan
Developer
Developer
Posts: 216
Joined: Thu Jul 04, 2013 8:44 pm
Location: Windows.h
Contact:

Post by Serkan »

Louise wrote: Sun Dec 17, 2017 8:08 pm Thanks serkan,

Another idea :

Ability to Highlighting of repeated occurrences of the currently selected word in the Editor.

This is added to project ,you can see how that works in the following image.
Your previous request (code prettify) is a bit complex and postponed for now.
Because ,there are things being affected by uncontrolled modifications.

HiliteSelection.png
Post Reply