-
Notifications
You must be signed in to change notification settings - Fork 57
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #166 from LucasBullen/bracket-matching
Issue #141 Matching bracket support with language configuration
- Loading branch information
Showing
8 changed files
with
470 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,5 @@ bin.includes = META-INF/,\ | |
.,\ | ||
schema/,\ | ||
plugin.xml,\ | ||
plugin.properties | ||
plugin.properties,\ | ||
resources/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
org.eclipse.tm4e.languageconfiguration/resources/css/dark.css
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/******************************************************************************* | ||
* Copyright (c) 2018 Red Hat Inc. and others. | ||
* This program and the accompanying materials are made | ||
* available under the terms of the Eclipse Public License 2.0 | ||
* which is available at https://www.eclipse.org/legal/epl-2.0/ | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
* | ||
* Contributors: | ||
* Lucas Bullen (Red Hat Inc.) - initial implementation | ||
*******************************************************************************/ | ||
IEclipsePreferences#org-eclipse-ui-editors:org-eclipse-tm4e-languageconfiguration { | ||
preferences: | ||
'TM4EMatchingPairColor=27,98,145' | ||
} |
35 changes: 35 additions & 0 deletions
35
...rg/eclipse/tm4e/languageconfiguration/LanguageConfigurationBracketMatchingReconciler.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/** | ||
* Copyright (c) 2018 Red Hat Inc. and others. | ||
* All rights reserved. This program and the accompanying materials | ||
* are made available under the terms of the Eclipse Public License v1.0 | ||
* which accompanies this distribution, and is available at | ||
* http://www.eclipse.org/legal/epl-v10.html | ||
* | ||
* Contributors: | ||
* Lucas Bullen (Red Hat Inc.) - initial API and implementation | ||
*/ | ||
package org.eclipse.tm4e.languageconfiguration; | ||
|
||
import org.eclipse.jface.text.IDocument; | ||
import org.eclipse.jface.text.ITextViewer; | ||
import org.eclipse.jface.text.reconciler.MonoReconciler; | ||
|
||
public class LanguageConfigurationBracketMatchingReconciler extends MonoReconciler { | ||
public LanguageConfigurationBracketMatchingReconciler() { | ||
super(new LanguageConfigurationBracketMatchingReconcilingStrategy(), false); | ||
} | ||
|
||
@Override | ||
public void install(ITextViewer textViewer) { | ||
super.install(textViewer); | ||
((LanguageConfigurationBracketMatchingReconcilingStrategy) getReconcilingStrategy( | ||
IDocument.DEFAULT_CONTENT_TYPE)).install(textViewer); | ||
} | ||
|
||
@Override | ||
public void uninstall() { | ||
super.uninstall(); | ||
((LanguageConfigurationBracketMatchingReconcilingStrategy) getReconcilingStrategy( | ||
IDocument.DEFAULT_CONTENT_TYPE)).uninstall(); | ||
} | ||
} |
Oops, something went wrong.