I'm working on a project in MS Visual C++, unfortunately the code is
completely tied to that environment and that IDE so I'm trapped.
Visual Studio has an SDK to interface to the IDE, for doing tool
plugins, etc. Recently, the VS team added a new free level to this VSIP
program. Previously, the VSIP SDK was only available for a fee. This
would only be interesting if the answer to this embedding Ruby question
involves tweaking VS.
http://msdn.microsoft.com/vstudio/partners/
http://www.vsipdev.com/
http://www.vsippartners.com/programoverview.aspx
Also, you can extend VS w/o having to use VSIP in a few ways.
The microsoft.public.vsnet.general newsgroup is the place to discuss
topics like this. My apologies that some of the people on that forum
might not know much about Ruby. 
Hope this is helps,
Lee
Lee Fisher wrote:
Visual Studio has an SDK to interface to the IDE, for doing tool
plugins, etc.
I think you misunderstand, I don’t want to modify the IDE at all, I want to
embed Ruby in my program which is compiled using the IDE. What I meant
when I said that it was tied to that environment was that it uses a lot of
Microsoftisms in the code and other things that make it unportable code.
So, I’m stuck using Visual C++ for this project, but I still want to embed
Ruby in the executable.
Looking around the directories, so far I found two .lib files that appear
to be what are needed to do this. I used the non-static one (the static
one caused errors about multiply defined functions), and once I moved the
.dll I found in the ruby/bin directory into the project directory things
compiled.
In fact, things seem to be working well, but I can’t seem to load the Ruby
file. I’ve tried with the file in the project directory, as well as in the
Debug directory, but Ruby doesn’t seem to find it. Any suggestions on how
I can figure out Ruby’s load-path? (Normally I’d do rb_p(“$:”) or
something similar, but since this is a GUI project I don’t know where
stdout/stderr go).
Thanks,
Ben
Lee Fisher wrote:
Recently, the VS team added a new free level to this VSIP program.
That’s great news, thanks Lee.
I have a much simpler VS question. In Tools->Options->Text Editor,
there is a list of supported languages. You can set the indenting
depths and tab usage for each language. Lots of folk here are editing
Ruby using VS, but there doesn’t appear to be a way to add Ruby as
a recognised language - obviously not for debugging purposes but even
for editing. Anyone have a clue how to fix this? It seems amazing to
me that a sophisticated IDE like this doesn’t have extensible editor
settings…
Clifford.