charlie bowman
2006-Feb-26 01:32 UTC
[Rails] how to format and syntax highlight code in html
I''ve written my own blog (I know typo is better, but I wanted the experience of writing my own) and I want to add syntax highlighting to it. I''ve read about using the ruby gem syntax but I can''t figure out how to implement it. I''ve also wondered if it could be used in my case. How does it work when you have a long line of code but the <div> your writing in is narrow? How would you fix this problem? charlie bowman recentrambles.com -- Posted via http://www.ruby-forum.com/.
charlie bowman
2006-Feb-26 21:49 UTC
[Rails] Re: how to format and syntax highlight code in html
Has no one tried to display code on thier blog? I know that there must be a good way of doing it. charlie bowman wrote:> I''ve written my own blog (I know typo is better, but I wanted the > experience of writing my own) and I want to add syntax highlighting to > it. I''ve read about using the ruby gem syntax but I can''t figure out > how to implement it. I''ve also wondered if it could be used in my case. > How does it work when you have a long line of code but the <div> your > writing in is narrow? How would you fix this problem? > > charlie bowman > recentrambles.com-- Posted via http://www.ruby-forum.com/.
Sean Stephens
2006-Feb-26 22:16 UTC
[Rails] Re: how to format and syntax highlight code in html
Take a look at the typo source and browse the code related to text filter used for syntax. <http://www.typosphere.org/trac/browser/trunk> There are lots of good things to learn from viewing Typo code besides this too... :) -Sean charlie bowman wrote:> Has no one tried to display code on thier blog? I know that there must > be a good way of doing it. > > charlie bowman wrote: > >> I''ve written my own blog (I know typo is better, but I wanted the >> experience of writing my own) and I want to add syntax highlighting to >> it. I''ve read about using the ruby gem syntax but I can''t figure out >> how to implement it. I''ve also wondered if it could be used in my case. >> How does it work when you have a long line of code but the <div> your >> writing in is narrow? How would you fix this problem? >> >> charlie bowman >> recentrambles.com >> > > >
charlie bowman
2006-Feb-27 01:24 UTC
[Rails] Re: Re: how to format and syntax highlight code in html
thanks, I didn''t even think about that. charlie bowman recentrambles.com Sean Stephens wrote:> Take a look at the typo source and browse the code related to text > filter used for syntax. > > <http://www.typosphere.org/trac/browser/trunk> > > There are lots of good things to learn from viewing Typo code besides > this too... :) > > -Sean-- Posted via http://www.ruby-forum.com/.