|
Tell us what you think of the site.
|
Autodesk Media & Entertainment User Community
|
Autodesk® 3ds Max®
|
|
Autodesk® Maya®
|
|
Autodesk® Softimage®
|
|
Autodesk® MotionBuilder®
|
|
Autodesk® Mudbox™
|
|
Autodesk® ImageModeler™
|
|
Autodesk® Sketchbook® Pro
|
|
Autodesk® Smoke on Mac®
|
| Script editor with syntax highlighting and more
|
|
|
Eric,
You can create a new Relational View and set it up as you wish. To create a new Relational View:
1. View > New Custom Relational View
2. In the window that pops up, right click anywhere and split vertically (if you want them side by side)
3. In the left pane, right click and select Set View > Custom Display Host. When the CDH is open, right click inside the CDH select Set View > ScriptEd [user add-on].
Setting the script log in the right view is a bit tricky. I would suggest you ‘edit’ the view file I bundled in and just copy paste the ‘frame’ information for the script log into your views right pane. To edit the view you’re making, close it, XSI asks to save, so save and then open it in notepad or wherever.
Be careful when setting the pane Size in when you’re setting up the Relational View. To make something stretchy make it a * instead of a pixel value. Once again, I’d suggest to take a look at the view that comes with the addon.
Do let me know if you have any problems. I’m silly busy these days so updates will be a bit slow.
Cheers,
P.S. Added your vote for code folding :)
|
|
|
|
Thx I’ll have go at it.
Eric T.
|
|
|
|
I’ve updated ScriptEd with two new features: (as usual available here, right click ‘save as’)
[LIST=1]
[*] ‘Save All’ button added
[*] Text butons have been replaced by bitmap buttons. I did this so that I can squeeze in more buttons if required. I want to keep ScriptEd as simple and usable as possible. I hope the icon images are self-explanatory. For some reason, tool tips aren’t working on them :-/ In order they are, New, Load, Save, Save As, Save All and Run Code. (Remember that the most frequent ones have shortcut keys)
[/LIST]
As mentioned in previous posts the following are on my to do list:
[LIST=1]
[*]Enable file loading when a text file object is dragged and dropped (dnd) into the editor
[*]Context sensitive SDK help on F1
[*]Code folding
[/LIST]
I’m fairly certain ‘load on dnd’ can be implemented with not much headache (fingers crossed). With the little experiments I did earlier with code folding, it is safe to assume implementation will be interesting (read nightmarish) :-) and context sensitive help I have no idea about.
Cheers,
|
|
|
|
just saw this thread saajjj, going to give this thing a go! to bad you couldn’t use scintilla text editor widget that came with softimage. although you probably could have put that in through the CDH since scintilla OSS. any ways i will comment on this once i am up and running
steven
|
|
|
|
One other thing I noticed the other day, is that if you have a script in the editor that hasn’t been saved, and close the editor there is no pop-up to ask if you want to save. Can this be added?
Eric T.
|
|
|
|
Brilliant! Such a “Save All” button might seem a silly little feature, but it should improve my chaotic workflow immensely… Keep up the good work...:biggrin:
The “other” Softimage community: si-community.com
|
|
|
|
Steven,
I am using wxWidgets implementation of Scintilla which they call wxStyledTextCtrl. Incidently the best documentation for that is done for wxPython!
Scintilla has tons of features, but implementing them is still quite interesting. For instance the auto-complete feature asks for just a string of words and a command pops up the auto-complete box, it’s left entirely up to the programmer to figure out how to construct that list, scanning through words etc and when to popup the box. Code folding is another feature which I reckon will be ‘fun’ to implement.
Hirazi Blue,
I’m glad it works for you
Eric,
Again a good suggestion, added to list. I’m pretty sure we can fire off a message box if there are any unsaved files.
Cheers,
|
|
|
|
Hello,
I’ve updated ScriptEd again, up to v1.2 now. The following changes have been made
[LIST]
[*]Added drag and drop support, you may now drag a file from the browser straight into the editor. (yay)
[*] Added a message box which asks if unsaved files should be saved, when ScriptEd is closed. Note: This is only called for a file which is already present on the disk and has been modified, i.e. a ‘loaded’, modified and unsaved file OR a ‘saved as’, modified and unsaved file. The message box is not called when the title of a file is ‘Untitled’
[*] On saving the document using the shortcut CTRL + S, the caret now returns to the position it was in when the save was initiated. Previously the caret would reset to the start of the document.
[*] Fixed bug where if auto-complete was active in prefs.ini, ScriptEd was ignoring this on startup.
[/LIST]
As usual the latest .xsiaddon can be downloaded from here (right click, ‘save as..’)
My to do list now includes the following:
[LIST]
[*]Context sensitive SDK help on F1
[*]Code folding
[/LIST]
I’m not too sure about how the SDK help is going to be triggered, initial research has returned at best bleak resulsts :-/ For the timebeing, I’d suggest to keep the SDK help open all the time and use Alt+TAB ruthlessly (This is my SOP).
I will probably tackle code-folding next.
I’ve updated the screen shot in the first post.
|
|
|
|
Hi guys,
I’ve uploaded a new version of ScriptEd, downloadable here
[LIST]
[*]The major update is the addition of code folding :biggrin: The preferences dialog box has been modified to accomodate enabling/disabling code folding as well.
[*]Another minor update is the addition of smart indentation. Previously on hitting ‘Enter’ the caret would go to the first column of the next line. Now, however, the caret should go down to wherever the current line starts from. This will help specially when you’re sitting in multiple nested loops.
[*]Lastly, I’ve added a ‘Recent Files’ text as the first selection to the combo box on the top left corner. This so that people who use ScriptEd for the first time aren’t confused about it’s purpose.
[/LIST]

I’d like to discuss one issue which has been nagging me. This regards the user being asked to save modified but unsaved files when ScriptEd is closed. Currently, if the user says ‘Yes’, ScriptEd will only save those files that are already on disk. As mentioned earlier only ‘loaded’/modified and ‘saved as’/modified files are saved. So if you have been writing a fresh script and haven’t saved it at all, when ScriptEd is closed, this text is lost forever.
There main reason I’ve had to resort to this is because there doesn’t seem to be any way to catch the event when the ‘X’ (close) on the ScriptEd window is clicked. What happens right now is:
1. The user hit’s ‘X’
2. ScriptEd window closes
3. If there are any unsaved files (present on the harddrive), a popup asks whether to save unsaved files.
Ideally speaking I would have like to be able to trap the event between #1 and #2 above. In this case, the user would be asked something like ‘There are unsaved files, still quit?’. If the user replies ‘no’ then the ScriptEd window remains open. The user is then free to save the files wherever.
One roundabout way of ensuring that no loss of data occurs is:
1. The user hit’s ‘X’
2. ScriptEd window closes
3. If there are any unsaved files (previously saved or not), ask user if these files should be saved.
4. User says ‘yes’ (save unsaved)
...start loop on unsaved files…
5. Display the unsaved file in a very simple read-only text box with a ‘save as’ dialog. This will ensure that the user knows which file is being saved,
...end loop…
The above is a hack, and it’s fairly ugly. Another solution to the same problem could be to:
1. Save normally all those modified files present on disk (this is what happens right now)
2. If a file name doesn’t exist for a particular tab i.e. it’s ‘Untitled’, save the contents of this tab in a temp folder. The proper extension could be attached to each temp file name by looking at the active script for that tab.
3. A popup could then inform the user if any temp files have been created.
Altough this isn’t an elegant solution, I think it’s ‘less ugly’ than the one described first.
Do you guys have any preference either way? I personally prefer the 2nd approach.
I noticed in my server stats that there have been links from other sites. I appreciate the free promotion :smile: Once I’m happy with the release I’ll post this in other xsi related forums as well.
Lastly, the main thing now left in my to-do list is opening up context sensitive help on F1. I will unfortunately be very busy for the next 3-4 weeks, so I may not get time to look into it. As mentioned earlier, my hasty research suggests it is possible, but right now I have no idea how the implemention will work. Once this last feature is implemented I’ll release the source code.
As usual, feedbaack is very welcome
Cheers,
P.S.: First post of this thread has been modified to reflect the new features. Screen shot updated as well.
|
|
|
|
Hey saajjj,
I think the 2nd way to deal with the unsaved files is fine with me. Would it be possible to set the temp directory?
Eric T.
PS - Thanks for your work on this plug-in. I know all too well how busy life can be on top of making plug-ins like these. Great work!
|
|
|
|
| Settings
| Choose Theme color:
|
|
|
|
|
|
|