mirror of
https://github.com/JetBrains/intellij-sdk-code-samples.git
synced 2025-07-28 01:07:49 +08:00
formatter.md: Fix minor grammar issues
This commit is contained in:
parent
a390b5e023
commit
2e5b41cc92
@ -1,6 +1,6 @@
|
||||
# 16. Formatter
|
||||
<!-- Copyright 2000-2024 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. -->
|
||||
|
||||
<!-- Copyright 2000-2023 JetBrains s.r.o. and contributors. Use of this source code is governed by the Apache 2.0 license. -->
|
||||
# 16. Formatter
|
||||
|
||||
<link-summary>Sample implementation of Simple language formatter.</link-summary>
|
||||
|
||||
@ -23,7 +23,7 @@ The formatter controls spaces, indents, wrap, and alignment.
|
||||
|
||||
## Define a Block
|
||||
|
||||
The formatting model represents the formatting structure of a file as a tree of [`Block`](%gh-ic%/platform/code-style-api/src/com/intellij/formatting/Block.java) objects, with associated indent, wrap, alignment and spacing settings.
|
||||
The formatting model represents the formatting structure of a file as a tree of [`Block`](%gh-ic%/platform/code-style-api/src/com/intellij/formatting/Block.java) objects, with associated indent, wrap, alignment, and spacing settings.
|
||||
The goal is to cover each PSI element with such a block.
|
||||
Since each block builds its children's blocks, it can generate extra blocks or skip any PSI elements.
|
||||
Define [`SimpleBlock`](%gh-sdk-samples%/simple_language_plugin/src/main/java/org/intellij/sdk/language/SimpleBlock.java) based on [`AbstractBlock`](%gh-ic%/platform/code-style-impl/src/com/intellij/psi/formatter/common/AbstractBlock.java).
|
||||
|
Loading…
x
Reference in New Issue
Block a user