Giter VIP home page Giter VIP logo

language-renpy's Introduction

Ren'Py language support in Atom

Build Status

Adds syntax highlighting and snippets to Ren'Py files in Atom. It also adds syntax highlighting to GitHub files, markdown code blocks and GitHub Gist (more info here).

renpy-banner

Originally converted from the Python package for Atom.

Syntax highlighting test: GitHub Lightshow

Contributions are greatly appreciated. Please fork this repository and open a pull request to add snippets, make grammar tweaks, etc.

Ren'Py is a Visual Novel development tool, available from www.renpy.org

Thanks to Koroshiya (Sublime-Renpy).

Getting Started

Installation

When using Ren'Py 6.99.14.2 or higher, go to preferences and select Atom as your text editor.

With Atom already installed, open the Settings tab: File>Settings (or with Ctrl+,)

Click in + Install and search for renpy then click in Install button of the package language-renpy.

It's also possible installing using the cli command apm (atom package manager):

apm install language-renpy

Usage

Open a .rpy file or create a new one and test the syntax highlighting of the Ren'Py. You can also use the example file available on the package repository.

Snippets:

Snippets are pieces of code like in the following example.

Snippets

The usage is done with keywords followed by a Tab to insert the snippet.

For example, there's a snippet with useful links, type dochelp and press Tab or Enter.

You can check the snippets list while editing a .rpy file, just open the Command Palette (Ctrl/Cmd+Shift+P) and search for Snippets: Available or go to the package settings (Settings>Packages>language-renpy>Snippets).

Snippets are added by need, so suggestions are welcome.

language-renpy's People

Contributors

ankushagarwal avatar aroben avatar benogle avatar cronos87 avatar dralletje avatar gitter-badger avatar justinnoah avatar karel-brinda avatar kennethreitz avatar kevinsawicki avatar koroshiya avatar mathiasbynens avatar maxbrunsfeld avatar morganwillcock avatar msabramo avatar peterdavehello avatar renpytom avatar ricpelo avatar syndbg avatar warunsl avatar williamd1k0 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

language-renpy's Issues

Colorblindness issue

Hey guys, I really like renpy and I've been having a blast getting to know the software, but I'm having issues with the color scheming in Atom. I'm slightly colorblind, and it makes it difficult to read certain words, especially in your custom-made theme for Atom. Would it be possible to make your theme more easily editable for an old coot like me?

Snippets suggestions

Write here your suggestion for a snippet.

Example:

keyword: dochelp
body:

## Visit the site for documentation or help of Ren'Py engine. ##
## Documentation:
    "http://www.renpy.org/doc/html/"
## Wiki-Old Documentation:
    "http://www.renpy.org/wiki/renpy/Wiki_Home_Page"
## Forum:
    "http://lemmasoft.renai.us/forums/viewforum.php?f=42"
## Package Documentation:
    "https://github.com/williamd1k0/language-renpy#getting-started"

Symbols?

Is there any way to get labels into the symbols view for quickly jumping around a file/project? It looks like Atom uses ctags but I'm not sure how that would work on Windows, or even if language-renpy would benefit from it.

Remove the Python scope

  • "Remove" source.python
  • Solve multi-line string conflicts (override source.python)
  • Temporary update from source.python (if necessary)

TextMate bundle for PyCharm support

TextMate is a MacOS editor. PyCharm has a TextMate plugin that allows to use TextMate bundle's for code highlighting purposes.

In order to do so, grammars/renpy.cson needs to be converted to a JSON and then to a PList file, which is a really easy to automate process through GitHub actions. The result would be a bundle that can be loaded into PyCharm and offer code highlighting capabilities.

Would this repository be a good place to host such an action so that at release time, an additional asset was created with the corresponding bundle? I can develop the workflow.

default

the keyword "default" does not have any highlight. I think it should behave like "define".

How can I contribute for a new language?

Since I don't know where I can contribute to add a new language, I believe this is the right place to ask.

Is there a way that I can add a new language?
The language that I want to add is Serbian.

If I need to post an example of the translations, please let me know so that I can attach the example.

EDIT: I am stupid. I just noticed that these are language packages for Atom.

Grammar attempts to include non-existant 'source.regexp.python.renpy' scope

๐Ÿ‘‹ I'm the primary GitHub maintainer for Linguist which is used for syntax highlighting on GitHub.com.

As part of this syntax highlighting, Linguist and thus GitHub.com, uses this grammar for highlighting Ren'Py files.

Our grammar validator has detected an error with this grammar:

  • repository vendor/grammars/language-renpy (from https://github.com/williamd1k0/language-renpy.git) (1 errors)
    • Missing include in grammar: source.renpy (in grammars/renpy.cson) attempts to include source.regexp.python.renpy but the scope cannot be found

This is caused by:

'regular_expressions':
'comment': 'Changed disabled to 1 to turn off syntax highlighting in โ€œrโ€ strings.'
'disabled': 0
'patterns': [
{
'include': 'source.regexp.python.renpy'
}
]

This section needs to be redefined, removed or the scope added to the grammar.

Requests to add new keywords

If you noticed any keyword or statements missing or a new one was created, ask here to update the syntax highlighting, pull requests are also welcome.

โ„น๏ธ You can test if already exists a keyword using the GitHub Lightshow.

Simple request example:


Keyword:
dissolve > transition statement

Usage:

show bg washington
with dissolve

Getting Started

It would be nice if the README covered how to get started with Ren'Py and Atom, at least for those of us who aren't familiar with the latter.

Error publishing

Error

bash: /dev/tty: No such device or address
error: failed to execute prompt script (exit code 1)
fatal: could not read Username for 'https://github.com': No error

Known issues

Some problems are not fixed yet.

  • Text tags
  • Menu and Label (GitHub)
  • Menu without name
  • Some keywords to add
  • Remove illegal keywords
  • Label comments and text tags with url search

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.