klorenz / atom-regex-railroad-diagrams

display regex as railroad diagram, if cursor moves to it
MIT License
250 stars 31 forks source link

What languages does this support? #74

Closed Dangthrimble closed 7 years ago

Dangthrimble commented 8 years ago

I've installed the package, opened files with regex in them and created new buffers and typed regex into them but no railroad diagrams appear. I've even restarted Atom to no avail. Does this only work for certain languages? Can the display be toggled? Or am I missing something more fundamental?

Thanks

klorenz commented 8 years ago

Hi Dangthrimbie,

basically it supports all languages, which have atom syntax-highlighting and mark its regular expressions in a reasonable way. But there are some special treatments for languages like python, ruby, etc.

The display toggles automatically as soon your cursor in on a regex.

Which language do you miss?

Best regards, Kiwi

SolomonShorser-OICR commented 8 years ago

I often have regular expressions quoted as strings to pass on to some other function, and the plugin doesn't seem to be able to handle those, for example (in perl): $rnd->randregex('\w{16}');

Would it be possible to have a feature that the user can manually trigger when a regex string is highlighted by the user?

PurpleMagick commented 7 years ago

I was wondering why I couldn't get this extension to work. All of our codebase is using tab characters instead of spaces. When I saw this issue, I tried converting one file to spaces and the extension immediately worked. Then JSCS immediately threw a fit.

klorenz commented 7 years ago

Hi all, I implemented @dflocks feature request, which should fix the initial request. @PurpleMagick, I also removed a former workaround, which calculated with tabs and spaces, so maybe your issue is also fixed.