Source Code Viewer Plugin

Viewer and VFS (Virtual File System) plugins.

Source Code Viewer Plugin

Postby steve » 20 Nov 2005, 02:40

See also: Syntax coloured source-code viewer (32 & 64 bit)

Source Code Viewer is a freeware plugin for Directory Opus (32-bit only). It provides an enhanced viewer pane for viewing your source code using the freeware Scintilla control (http://www.scintilla.org). This control provides a host of features including syntax colouring, line numbering, code block folding, word wrapping and brace matching amongst others.

The plugin also allows you to edit your code, search for text, goto lines, add your own languages, etc.

Author: James Dickson support@jdnet.co.uk
Version 1: http://www.jdnet.co.uk/forum/index.php?showtopic=58
Version 2 (beta): http://www.jdnet.co.uk/forum/index.php?showtopic=119 -- See also: viewtopic.php?t=992

Version 2 (beta) requires you to install a special version of Scintilla Text Editor (SciTE): SciTE with Extensions.

Update:

JDNet.co.uk has been down for quite a while so the links above may not work. Here are two alternative downloads. I think they're the latest versions but I may be incorrect. --Leo

Version 1: SourceCodeViewer.zip
Version 2 (beta): SourceCodeViewer_Beta.zip
Last edited by steve on 27 Mar 2006, 22:46, edited 1 time in total.
User avatar
steve
Admin
 
Posts: 1994
Joined: 02 Nov 2004, 18:50
Location: Blandings Castle
OS: Windows Vista 32-bit
Opus: Illuminati

Plugin doesn't install properly

Postby kae99 » 22 Nov 2005, 15:57

Hi,

I have installed the plugin following the instructions included in the readme.txt, but the Source Code Viewer plugin is not working.

It doesn't appear in the list of installed plugins (Preferences/plugins) and, of course, it doesn't colour my files when I see them in the viewer panel.

I have found the dlls have dependencies with msjava.dll and msvcr71.dll which weren't installed in my system, but installing them hasn't solved the problem.

Why isn't the plugin/installation working?

Thank you.
kae99
 
Posts: 3
Joined: 22 Nov 2005, 15:49

Postby leo » 22 Nov 2005, 16:03

I don't have MSJAVA.DLL on my system either but the plugin works here, so it's not that. Hopefully James (who wrote the plugin) can help you.

BTW there's also MSVCP71.DLL in addition to MSVCR71.DLL in the plugin's dependencies. Got both?

You've got the Scintilla.dll and SciLexer.dll installed as well? I think the instructions say to copy them to system32 but I found putting them in the Directory Opus directory (i.e. alongside dopus.exe) works as well if you don't want to add things to System32.
User avatar
leo
Admin
 
Posts: 14449
Joined: 07 Nov 2004, 01:30
Location: London, UK
OS: Windows 7 64-bit
Opus: Illuminati

Postby kae99 » 23 Nov 2005, 01:28

Thank you for the help, but I have all the dlls installed correctly :( (I copied the Sci*.dll to the system32 folder directly).
kae99
 
Posts: 3
Joined: 22 Nov 2005, 15:49

Postby kae99 » 23 Nov 2005, 11:02

Problem solved.

You were right, I rechecked my dlls and I was missing msvcp71.dll (my dependencies program didn't alert me, i don't know why).

I copied this dll to the dopus directory and the Source Code Viewer plugin appeared in the list after refreshing.

Thank you very much for the help.
kae99
 
Posts: 3
Joined: 22 Nov 2005, 15:49

Postby vnation » 10 Feb 2006, 13:04

Maybe there is a problem with windows xp and Athlon 64. I turned off the Data Execution Protection and now this viewer is working.
vnation
 
Posts: 1
Joined: 10 Feb 2006, 12:59

Toggle Word Wrap?

Postby kelaudemm » 18 Apr 2006, 10:59

Can anyone tell me how to toggle word wrap in the SVC?
User avatar
kelaudemm
 
Posts: 3
Joined: 06 Apr 2006, 00:54
Location: Seattle

Postby leo » 18 Apr 2006, 11:47

Right-click the window to get a context menu that allows you to set word wrap and other options.
User avatar
leo
Admin
 
Posts: 14449
Joined: 07 Nov 2004, 01:30
Location: London, UK
OS: Windows 7 64-bit
Opus: Illuminati

Postby kelaudemm » 19 Apr 2006, 20:04

Awsome! I have it working and I added the batch and html/xml config from the forum also. Groovin. Can anyone tell me how to go about defining my own config. I now need SQL config. Maybe a tutorial somewhere on building configurations? Much obliged.
User avatar
kelaudemm
 
Posts: 3
Joined: 06 Apr 2006, 00:54
Location: Seattle

Postby leo » 19 Apr 2006, 23:31

I think Beta 2 will colour SQL files out-of-the-box since it uses SciTE's configuration files.

C:\Program Files\Scintilla Text Editor\sql.properties
User avatar
leo
Admin
 
Posts: 14449
Joined: 07 Nov 2004, 01:30
Location: London, UK
OS: Windows 7 64-bit
Opus: Illuminati

Postby leo » 27 May 2006, 03:04

Attached is a modified SciTEGlobal.properties for use with Source Code Viewer version 2 (beta) which makes a couple of changes to the default configuration which comes with SciTE:
  • All fonts changed to BitStream Vera Sans or BitStream Vera Sans Mono. (The default SciTE config uses several different fonts in various sizes which I found ugly, especially as Comic Sans was one of them.)
  • Display of indentation and guide whitespace turned off by default.
  • Colour of whitespace markers made a little lighter.
  • End-of-line mode set to "CRLF" and "auto", although this seems to affect SciTE only, not the plugin, for some reason.
The original config file is also in the zip so you can use a diff tool to see exactly what I've changed. These changes are not huge but, as I wasn't familiar with SciTE, it took some searching to work out what to do and I figure if may save other people some time. (Thanks also to Jamie for helping me find what needed to be edited without having to RTFM too much. :))

Fonts

The BitStream Vera Sans family of fonts are not part of a standard Windows install so you'll need to grab and install them before using the config file, or edit the fonts to something else. If you don't then you'll get some default fonts used. If the main font you see is not monospaced then you haven't installed the fonts properly.

The fonts are freely available from the Gnome FTP server and I've also attached the current version to this message to make life easier.

Use an Opus button which runs Copy INSTALLFONT as a quick way to install the fonts. (Unzip and select them first.) Or you can go to your Fonts folder and select Install Fonts from the menus.

Config File

The config file itself should replace C:\Program Files\Scintilla Text Editor\SciTEGlobal.properties if you've installed SciTE to the default location.

Screenshot

Click the thumbnail below to see what the fonts look like. They work well for source code.
Attachments
NudelSciTEConfig.zip
My modified SciTE config file.
(14.71 KB) Downloaded 913 times
ttf-bitstream-vera-1.10.zip
BitStream Vera Sans font family
(344.86 KB) Downloaded 2163 times
SCV_BSV_fonts.png
SourceCodeViewer using BitStream Vera fonts.
User avatar
leo
Admin
 
Posts: 14449
Joined: 07 Nov 2004, 01:30
Location: London, UK
OS: Windows 7 64-bit
Opus: Illuminati

Postby nitrix-ud » 20 Jun 2006, 09:23

Hi all,

I installed SCV beta2, and i can't make it work with .css and .js files

I does work with .htm, .php, .txt, .ini and many many more

I use the standard scintilla installation (with extensions)

if i disable text viewer, scv does not work either, i just get a blank viewer pane

Any idea ?

Cheers, Nico
nitrix-ud
 
Posts: 64
Joined: 09 Feb 2005, 16:42

Postby timpani » 03 Jul 2006, 04:14

I installed the Source Code Viewer plugin and was able to use it to view and edit php and css files. A few days later, I tried to use it again - and it's not working for me. When I choose that plugin to view documents, they look blank. Using the text viewer on the same documents shows the contents.

Given that it was working at first, I'm baffled. I've tried reinstalling it, carefully following the instructions packaged with the plugin, but to no avail. I have the dlls mentioned earlier in this thread.

The plugin appears on the list of plugins, and is checked as active. However the "configure" option for the plugin is greyed out.

Does anyone have any ideas about what the problem might be?
timpani
 
Posts: 2
Joined: 03 Jul 2006, 03:47

Postby timpani » 03 Jul 2006, 04:41

-very-small-voice-on-
never mind
-very-small-voice-off-

There's a vertical divider (not sure what for, but it's there) and I somehow managed to get it dragged all the way to the left edge of the viewer pane.

I'll just go and sit quietly in the corner now...
timpani
 
Posts: 2
Joined: 03 Jul 2006, 03:47

Postby leo » 03 Jul 2006, 04:55

I thought that the blank panel was a bug at first but if you view some C++ source code you'll see what it's for (see screenshot).

For most other file formats it won't display anything but a blank pane.

You can turn it off by pressing Ctrl-T, or by right-clicking the viewer and selecting Options -> View Tree.
Attachments
scv-tree.png
User avatar
leo
Admin
 
Posts: 14449
Joined: 07 Nov 2004, 01:30
Location: London, UK
OS: Windows 7 64-bit
Opus: Illuminati

Next

Return to Plugins