WebScripter hold ups

3 months after the first Intel native release and still I have not produced anything like I had hoped. I made a terrible mistake in deciding what the first new feature I should add was: code folding. This was a intensely complicated feature to implement and complicated the editor down to every detail from copy/pasting, saving/loading and typing/syntax styling. Let it be known, WebScripter does have a pretty nice implementation working but the system has put such a strain on the text editor API WASTE it has forced to remove it altogether. This was a long time coming considering the crippling speed issue and developer failing to provide support. He is btw basically quitting WASTE, I should have known this 2 years ago…

 

Code Folding Preview
Next version preview (2.1)

I wrote about this headache before regarding PascalGladiator but the root is in WebScripter. This means before the next version I will be up-rooting the text editor and implementing the Cocoa system NSTextView using the new experiemental PasCocoa Objective-C runtime wrapper. I just can’t accept that I am developing programmer tools that rely on a text editor at the core but editing files around 1000 lines is too slow to use. Before code folding it was still a joke, but now it’s just silly.

However I still was able to create some new features that are in development but near the end.

First is the Reference Mode. I wanted this feature for a while now as I’m sick of switching back and forth between browsers and editors to get function arguments and the likes. What’s special about the system in WebScripter is it allows you to design search rules (using Regular Expressions) that can crawl and index a site like a search engine. There will be basics pre-loaded with the release but you can customize and add new web sites on your own. After a site has been indexed you can search the contents from the book mode pane (seen in the screen shot above) or contextual click on code and it will bring you right to the page you need in the reference library. Really useful feature and it’s totally customizable to the user.

Second is inline error checking. I felt the error checking process was intrusive (bringing down a list above the editor, however this will remain available) and that the information could be contained in the gutter using icons and floating help windows. In PHP which has great error handling you can see the stack trace in the gutter and the value of variables by dragging the cursor over them in the text editor. Additionally, real time syntax checks will be available as you type.

But the changes I really wanted to make are more towards user experience and simplifying the preview/run/error system which is just cluttered as of now.  This should have all happened by now if not for the the mistakes I made. Until next time…

PasCocoa: First thoughts

It may have been well over a year now but when I heard the news about someone making a Pascal Objective-C bridge (then with no name) I just ignored it for some reason. Maybe because 10.5 had not be released and there was no real reason for unless I wanted to make an Cocoa application. I should have taken notice at least so I could replace my WebKit code with native Pascal. As of 10.5 we now have the HICocoaView API which lets us use NSView classes in Carbon windows, which means: Cocoa is open game for me now. Even if I have to write the wrappers in Objective-C I can use them in Carbon.

A few weeks ago and I have compiled and ran some of the example projects (in PascalGladiator) and started some simple tests with NSTextView and NSOutline/TableView, 2 API’s which there Carbon equivalent is terrible and I spent hours trying to mimic the Cocoa version which has become the standard.

I was thrilled to see in not too long I had the 2 API’s working in a Carbon window and I can say they are designed much better then their Carbon counter parts. WASTE requires at least 1-2 weeks of full time work to get a good HIView wrapper but NSTextView was working I would argue better after just a few.

However there have been the PasCocoa bindings are incomplete and some basic features like overriding a method in an existing NSObject class is not available. Adding methods to Objective-C runtime for delegates/controllers is also a kludge. I plan to start making contributions to the project as well as adding macro support and code generation utilities in PascalGladiator to aid the process.

At any rate this is a great start and something I fully support as the future of Mac development using Pascal.

PascalGladiator: Future

With the release of 0.4 and what seems to be more bugs than fixes I have hit a cross roads. The text editor API I have been using for years instead of MLTE has proven to be obsolete and no longer suitable for development. The developer has more or less abandoned the project and there is an absolutely crippling speed bug which you have no doubt noticed. The single bug along with the terrible speeds when applying/retrieving attributes to text has cost be countless hours in the hundreds working around this and still the end result is typing in files larger than 1200+ lines is dog-slow.

The final nail in the coffin when code folding which put strain on the already fragile system and basically wrecked the editor. Even if I remove it all the hacks I made in my WASTE HIView have tampered with some basics like syntax coloring copy/pasting and the bugs are there to stay. Worst of all problems is that hidden objects had to be inserted into the text which MURDERED the editing process and was hacked to pieces to even work. I should have never implemented code folding if that was the only option.

I’m trying to release commerical grade development tools which have a text editor at the core and my system is totally broken and hundreds of hours have been poured into this obsolete technology. Depressing…

Unless I change now, I’m doomed. MLTE is just to primitive to handle what a good editor needs. Is that really all the Mac has to offer Carbon programmers? But there is one option…

With the release of 10.5 there is an HICocoaView API which allows the wrapping of a NSView into a Carbon application. I thought this was cool at first, but overlooked until my current crisis. NSTextView is a great API which is FAST and offers a great system for applying/retrieving custom attributes to text. I never considered it because it was Cocoa and thus I could not use it. My HIView WebKit view wrapper I use is based on Objective-C code that I slapped together (barely) and uses Carbon events, which works well enough. This is the only HIView based API that Apple bothered to bridge for Carbon. Shame…

I’m sorry to say the next version of PascalGladiator will not be anytime soon because I am committed to removing WASTE from my code once and for all and using HITextView, which I will be authoring using PasCocoa, all native. Also get prepared for PascalGladiator to be 10.5+ no exceptions. Code folding will need a serious overhaul which I may just omit for since I’m so sick of it. I wish the only Intel native version was more stable, next time!

PascalGladiator 0.4 Released

The long awaited release which is Intel 10.5 compatible (requires it actually) and re-written in FPC, even compiling itself! Lots of new featuers including: code folding, typing helpers, go to symbol and smoother file loading but new crashes and bugs were introduced also due to some serious work in the editor/syntax parser and MWP -> FPC port.
I’m sorry to say at this point that this is still beta software and much under development, which means bugs and crashing. I made the terrible decision to include code folding in this release (I did this so I could test the feature for WebScripter) but it consumed a HUGE amount of time and complicated dozens of other already complicated parts of the program. In short: not worth it. The debugger is still in the same semi-functional state and I had no time to work on this area.
The next release will feature just bug/crash fixes and focus on the debugger once and for all.
Version 0.4 running on 10.5
Version 0.4 running on 10.5
Changes:
  • Code folding has been implemented into WebScripter and a language definition to work with PascalGladiator. This is a great way to get around the inherent speed bug in the text engine WASTE by closing functions you don’t need to look at.
    • Code folding is column-sensitive. That means the column in the line where the range opens, must match the closing line. The result of this is you may find your code is not folding property because the columns are not aligned and you will have to “doctor” some lines.
  • 2 new preference options to disable code folding or ignore drawing the level bars in the gutter (like Xcode).
  • Auto-pairing now respects context so commas etc… won’t be paired when typing within comments for example.
  • Because code folding introduced a few too many menu items there is now a VIEW menu freeing up the editor menu.
  • The debugger is in black and white now which helps to correct the speed problem a little.
  • The console now always keeps scrolled to the bottom (when focused).
  • There is a new UNIVERSAL compiler target in the target preferences which compiles a PPC and Intel binary, then combines them into a universal binary. Also note the universal SDK field where you can specify the SDK to link against.
  • Documents do an accurate job of remembering the selection and scrollbar position of the last saved state.
  • File info window now returns more information. 1) line count. 2) The binary type for executables (PPC, Intel or Universal) 3) The file type and 4) for libraries and frameworks a list of symbols is show (using ‘nm’ utility), but is just in text form without a way to filter results (for now).
  • If you try to build while the target application is running it will bring the application to the front.
  • Errors can be selected from the list now even if the file is not in the project but can be located by paths and related projects.
  • The file list when contextual clicking on a related project is now in alphabetical order.
  • Files now load smoothly without hanging periodically. However the styles don’t appear in sections so the file is black until loaded 100%. This is because incremental applying of styles KILLS WASTE performance.
  • There is a “Go to Symbol” command in the editor menu (command-shift-T) which lets you quickly jump to any symbol in the project instead of scrolling through long menus. After using the find function to navigate functions in large files I decided this would be better.
  • There is an application preference to set the MallocDebug library in GDB (set env DYLD_INSERT_LIBRARIES /usr/lib/libMallocDebug.A.dylib). Read the MallocDebug manual to learn about this useful tool for debugging dangerous memory scenarios.
  • Code completion is not much faster which you will notice on projects with over 2000 symbols.
  • A new simple, very useful command “Go to Cursor” in the edit menu which will bring the cursor into view if you scrolled away from it. For example, if you scroll to the top of the document to examine some record fields you hit command-option-* and go right back to where you were typing.
  • New [obj] macro which creates an empty object declaration.
  • New [conc] macro which creates”+$CURSOR+”++”. Don’t forgot the use macros, they’re cool!
  • Added new Pascal typing helpers (enable/disabled in preferences) which will auto-complete blocks like begin/end, record/end and auto-ident blocks such as: type, then, var, uses. Pretty handy or annoying, you decide.

WebScripter 2.0.3 Released

11/04/08: WebScripter 2.0.3 Released. Universal binary at last! This was no trivial step for me as I changed Pascal compilers (FPC) and development environment. Good-bye Pascal CodeWarrior and over 10 years of programming with it!

As an interesting side note WebScripter 2.0.3 is now being developed with my IDE PascalGladiator which was in turn developed mainly from components of WebScripter and the application framework.
Changes:
  • Symbol filter in the side pane was removed for a cleaner look.
  • Updates can be downloaded automatically from within the application.
  • A new slicker website design appears with this release.
  • Disabled window toolbar items no longer look too white on Leopard’s darker appearance.
  • Changed the list appearance (again) to look more Leopard.
  • Various menu items enable/disable properly now.
  • New application/document icon. Thanks to Jordan of www.onetoad.com.
  • Spell checker now works in the editor. There is also a spelling item in the contextual menu when you click on a word.
  • Find/Terminal panes animate as they open/close.
  • Icons in the preference window toolbars appear “selected” now. Doh!
  • Translucent drag images from lists now look better.
  • Menu items are now disabled if the command isn’t available. Doh!

PascalGladiator 0.3 Released

This update focuses mainly on changes to the debugger but there are other useful updates to the editor also. However there is still a nasty bug I haven’t been able to track which causes the application to run slowly after using the debugger. I’m sorry to say the debugger STILL isn’t fully functional yet but it does work for short sessions, which after you can just quit the app (it restarts quick). I think the next version will have the debugger working correctly.

Changes:

  • You can navigate errors in the console by using command keys (in the editor menu).
  • The first error in the console is auto-selected after a build.
  • You can set a label to files (like in the Finder) in the source browser by using file info. The coloring scheme is not very good yet however.
  • Document cursor selections are remembered.
  • The text in the find window is always selected when the window is opened (via command)
  • Creating new empty files inserts a default unit template. This file can be changed at: Contents/Resources/Templates/newfile.txt
  • $INCLUDE compiler directives are shown in the symbol browser.
  • Records and class symbols are closed in the symbol browser by default to avoid clutter.
  • Dragging a file from the project browser into text will insert a {$INCLUDE } compiler directive with the files name.
  • There is a function menu in the debugger editor. However, you can still only navigate within the file being debugged.
  • Stack frames without valid locations (from library code without source files for example) are not selectable in the stack frame browser and colored grey.
  • Common value types (i.e. strings, boolean, numbers, sets etc…) are colored in the debugger.
  • File info window (thus far is basically empty) by contextual clicking on a file in the browser. This is also how you can rename folders.
  • Function arguments longer than 255 characters are now handled correctly in the debugger.
  • Compiling syntax now updates the open documents text. Additionally, in the editor menu you can compile only the open editors syntax.
  • Killing the debugger session actually kills the program running.
  • Break points are 90% but still some quirks here and there.
  • Clearing all break points command in the project menu works. It also clears break points from all related projects!
  • Global symbols from the current file are shown in the debugger. This needs more testing as of now.
  • The SELF symbol is shown in the debugger.
  • Deeply nested pointers print values. However, fields from super-classes will not print yet citing a syntax error.
  • Mangled FPC symbol names (like TTABS_CREATE_$__APPEND) are cleaned up in the debuggers stack browser and readable.
  • Debugger always scrolls the execution stopped line into view.
  • Outstanding debugger issues with speed and long symbol values have been fixed.
  • There is a Add Frameworks item in the project menu that opens a choose dialog to the system frameworks folder.

PascalGladiator 0.2 Released

Big little release with many important changes. However, note that the debugger should just be ignored until I can get the ProcessUtils unit working under FPC 2.2.2. I haven’t been able to fix it without support from the developer and he’s busy right now. The debugger has new improvments but it’s still really slow and now fails to parse symbols with more than 255 characters of value output. I have been using this version to convert a few CW projects and it’s doing quite well.

Changes:

  • Find and replace, including find in project with searches current project and all related projects (in the projects group).
  • Cleaning projects deletes all items in the temporary build folder.
  • Files are marked in the browser if they need compiling (dirty).
  • Dynamic libraries and frameworks can be copied into the application bundles framework folder during build by checking the application target option.
  • You can now navigate files by contextual clicking on the item in file browser and selecting a function.
  • Compiling syntax in the project menu. This needs to be done after making changes or adding new symbols.
  • Class browser. Open in the Window menu.
  • All open documents are saved before building.
  • Debugger editor has a toolbar with the file path and potential modification date warning.
  • Projects have a new PROJECTS group for debugging programs that link libraries from external projects. Contextual clicking contains a sources item that lets you open files from the project.
  • Builds dynamic libraries and bundles from “Library” programs. Note that only dynamic libraries are tested and working.
  • Console window has a status toolbar.
  • Syntax errors are shown in the gutter with help tags when you click on them.
  • Break points are synched properly when toggled during debugging.
  • Fixed a bug causing speed issues when saving files with break points
  • Chasing arrows animation appears in the file browser when files are compiling.
  • Pointer/object values are printed in the debugger.
  • Viewing class hierarchy in contextual menu
  • CoreFoundation variables will print values (via CFShow) in the debugger.
  • Complex types like CFDictionary do not display very well however. Note you can see the raw CFShow output in the console window.

  • Fixed incorrect scrolling when saving bug.
  • Variables are drawn in red when there values change in the debugger.
  • Debugging processes can be killed.
  • Option to ignore notes and warnings from the compiler in the application preferences.
  • In the help menu are some quick links to FPC documentation in pdf format on the hard disk at /Developer/Documentation/Free Pascal Compiler.
  • Jumping to symbols in files outside of the current document nows works correctly.
  • Opened symbols in the debugger now remember their state between stack frame changes.
  • Crashes are handled in the debugger.

PascalGladiator 0.1 Released

This is a pre-release for testing and playing around, nothing is working 100%. NOTE: building/linking frameworks and static libraries is not working until I can figure out how this works. Can anyone offer some help? Clearly frameworks in FPC are off limits to users without expert UNIX knowledge. 😉

WebScripter 2.0.2 Released

6/15/08: WebScripter 2.0.2 Released. This is minor update with the following changes:

  • Fixed nasty bug that was over looked in the new file dialog when choosing a new folder.
  • Fixed a bug with single file uploading.
  • Included new users guide for trial version.
  • Minor improvements to the built-in preview with basic navigation and status bar.
  • Fixed syntax parser bug in CSS.
  • Browsers have a more Leopard look and feel.
  • Better looking close boxes for tabs and some panes.
  • Fixed some potential crashes when previewing in a new window.

WebScripter 2.0 Released

After a total rewrite of 1.0 and a new object-oriented application framework WebScripter 2.0 was released on 5/18/08. This followed the original (and only) 1.0 release on 4/20/06.

The official press release:

June 2nd 2008 – The Alchemist Guild today announced the release of WebScripter IDE 2.0, a web development environment for Mac OS X.

What is WebScripter?

WebScripter is an integrated development environment (IDE) for programming in several popular web scripting languages such as: PERL, PHP, CSS, HTML/XML, JavaScript and Ruby.

WebScripter offers powerful features to help improve productivity and manageability in all areas of the trade, including: text editing, previewing web pages, testing scripts, managing projects, navigating code and FTP integration. Designed with the principal in mind: “everything you need, needs to be where you need it” WebScripter will help give you a place to work where you’re productive and comfortable because you’re surrounded by the tools you need to get the job done.

Text editing is improved over standard editors by robust syntax coloring, scriptable macros that can run UNIX commands, drag and drop snippets and other shortcuts.

Web pages can be previewed from within the application, in external browsers or in real-time while typing.

Scripts such as PERL, PHP and Ruby can be executed and previewed, just like from the command like while helping you handle errors that may occur.

Code is made easier to navigate by the powerful syntax parser which collects information in your files (functions, variables, classes, etc…) and then lets you navigate them by that data.

For testing scripts on the web server, WebScripter features a built-in FTP client that lets you edit files directly on the server, just like a file on your hard disk.

What’s New?

2.0 in an exciting release because everything has changed. The original concept was scrapped and re-designed from the ground up with a modern OS X GUI using tabs for editing and split views for integrating features into a single window. The new design is compact, concise and helps to keep the user in close contact with the experience.

Notable features Include:

  • Scriptable macros
  • Shell commands
  • Auto-complete
  • Preview HTML live while typing
  • Function popup menu
  • Publish files to the web server in one-click
  • Built-in FTP support
  • Drag & drop code snippets
  • Browse projects using symbols
  • Organize code using projects
  • Error handling for PERL, PHP and Ruby scripts
  • Search files by project
  • Simulate user input when running scripts
  • Pseudo-terminal for testing scripts.
  • Execute scripts locally without the internet using Apache
  • Preview files in 3 modes

Cost and Requirements:

WebScripter 2.0 is priced for everyone, even students and hobbyists, for US $39 and will run on any Mac with 10.4 or higher installed.

Contact and URL:

Web Page: http://www.web-scripter.com
Developer: Ryan Joseph ([email protected])
Address: 1739 Mariposa Ave, Boulder CO 80302.