225 Commits

Author SHA1 Message Date
JohnHake
56ff3418e2 Fix text ranges 2019-10-07 13:39:02 -07:00
JohnHake
9b03c3b52a Fixed missing <depends> elements, refactored obsolete kotlin_demo. 2019-06-13 16:59:30 -07:00
John Hake
753b73daef Cleanup build warnings, updated since-build, removed ModuleComponent. (#154)
* Cleanup build warnings, updated since-build, removed ModuleComponent.

* Refactor facet_basics for functionality/clarity. Incorporate feedback.

* Incorporate additional feedback.
2019-03-11 19:13:44 +01:00
Yann Cébron
da7f650d6a Simple Language Plugin: cleanup plugin.xml 2018-12-18 09:42:02 +01:00
Steve Ramage
c551dd0d48
Update Simple.flex
Changed the fallback character from . to [^] since this serves as a basis of other lexers.
2018-08-22 18:26:49 -07:00
Dmitry Jemerov
e994ab2ed3 Fix nullability issues in SimpleStructureViewElement (IJSDK-333) 2018-03-19 12:18:43 +01:00
Vitalii Dmitriev
10efd969a9
Remove passing a file extension explicitly.
Hello!

In this code, the `SimpleFileType` instance passed as the first argument and the `"simple"` file extension as the second parameter.

As far as I can see in FileTypeManagerImpl:263:
```java
@Override
public void consume(@NotNull FileType fileType) {
  register(fileType, parse(fileType.getDefaultExtension()));
}
```
There is no need to declare it explicitly as it is taken by calling `SimpleFileType.#getDefaultExtension()` by default, so this parameter is redundant.

To make tutorial more simple, I suggest this removal: seeing the second parameter is a bit confusing when we're passing the same value, returned from `getDefaultExtension()`.
Since the tutorial shows the basics, not a flexibility of an API, the parameter can be removed.

Thanks!
2018-02-13 23:12:24 +03:00
Matt Ellis
752347cf5e Update custom language tutorial 2017-10-12 12:11:42 +01:00
Ian Lesperance
a725cd52f8 Explicitly depend on SimpleLanguage.INSTANCE (#34)
The use of `Language.findInstance()` implicitly depended on the fact that
`SimpleLanguage.INSTANCE` was referenced at some earlier point in time. In this
case, that happens because the instantiation of `SimpleParserDefinition`
triggers the instantiation of `COMMENTS`, which relies on
`SimpleTypes.COMMENT`.

When basing one's work on this sample project, however, one may run into
issues. Specifically, the absence of a custom comment token type will mean a
failure to correctly instantiate the singleton language object. Making the
dependence on `SimpleLanguage.INSTANCE` explicit prevents that issue from
occurring.
2017-02-16 00:12:29 +03:00
Yann Cébron
f9194eadf4 plugin descriptors: remove obsolete idea-plugin@version attribute (IDEA-163694) 2016-11-11 17:48:01 +01:00
cheptsov
b5d7eaf461 IJSDK-203 Confusing grammar and no info on comments and whitespaces 2016-11-03 16:45:34 +01:00
cheptsov
040464bc01 IJSDK-203 Confusing grammar and no info on comments and whitespaces 2016-11-03 13:23:01 +01:00
Yann Cébron
616ab0351f sample projects plugin.xml: update confluence to jetbrains.org links 2016-11-02 21:26:45 +01:00
cheptsov
e6109ae341 Fixed broken tests and compilation
Rollbacked some of Breandan's changes
2016-11-02 14:42:59 +01:00
Yann Cébron
404f3f4577 IJSDK-76 Optimize screenshot file sizes 2016-10-27 10:46:40 +02:00
Breandan Considine
10140f33d4 Prefer wildcard imports to maximize vertical visibility in code samples
Too bad there isn't a way to filter lines with Jekyll Liquid tags
2016-03-21 16:59:17 -04:00
Breandan Considine
f416f02ce2 Tidy up code samples and wrap at 80 chars #IJSDK-24 2016-03-21 16:08:47 -04:00
Yann Cébron
51adeed1ac simple_language_plugin: SimpleReferenceContributor cleanup 2015-12-09 20:27:56 +01:00
breandan
11062a0a1b Fix simple_language_plugin tests 2015-12-05 11:47:23 -05:00
breandan
75ac21b9ad Update plugin code samples to use canonical project structure 2015-12-05 08:56:10 -05:00
breandan
5b163015cc Fix compiler error 2015-12-03 16:41:31 -05:00
breandan
fca41b5a98 Share run configurations and inherit the project output path 2015-12-03 16:23:33 -05:00
breandan
6d2c407a43 Add code_sample projects as sub-modules inside intellij-sdk-docs 2015-12-03 15:28:36 -05:00
Vladimir Schneider
568ea64319 change FindUsages getWordScanner not to be static.
If it is static then there are multi-threading issues. When indexing multiple threads are running and overwriting the lexer state that the word scanner uses.

I copied the SimplePlugin find usages class and spent hours chasing index out range bugs. I also noticed that the SimplePlugin which I have installed in my plugin dev environment would once in a while cause an exception but I did not pay it much attention. The static word scanner is the source.
2015-09-16 02:06:53 -04:00
cheptsov
afa6b7c47f Renamed SimplePlugin to simple_language_plugin 2015-09-07 19:33:25 +03:00