Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Search view doesn't update matches for Xtext DSL code

オープン
#3,813 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
java
領域
desktop

調査の方向性

Start with the PositionTracker constructor in bundles/org.eclipse.search/newsearch/org/eclipse/search2/internal/ui/text/PositionTracker.java, especially the lines linked in the issue, and investigate how it tracks edits for files not using ITextFileBufferManager. The issue suggests a resource change listener as a possible direction; done means saving an edited Xtext DSL file updates the Search view to show fewer matches.

索引モデルが issue の本文から書いたものです。

説明

bug

Unfortunately I don't have a self containing example at hand, just saw the issue immediately by loking at the PR related to the Search view PositionTracker fix https://github.com/eclipse-platform/eclipse.platform.ui/pull/3802.

I can see it with custom Xtext based application that provides various DSL (text file based) implementations.

  1. Start Search -> File, make sure the filter matches some DSL files, like "Search for 'a'" text in any DSL file.
  2. Search view shows those DSL files (OK), highlighting text matches (OK)
  3. Double click on that file & remove the line with the match, save the file
  4. Search view is supposed to update the result to show less matches.
  5. For Xtext based DSL files this doesn't work - because Xtext by default doesn't use ITextFileBufferManager.

See org.eclipse.search2.internal.ui.text.PositionTracker constructor why this doesn't work:

https://github.com/eclipse-platform/eclipse.platform.ui/blob/1c1d72e1d84af68bd77eb4db785c11494662b644/bundles/org.eclipse.search/newsearch/org/eclipse/search2/internal/ui/text/PositionTracker.java#L61-L64

Of course it would be nice if Xtext would use "common" text file buffers API, but it's obviously design decision which was made several years ago and changing that would be either not possible or breaking existing API/code.

One possible solution on platform UI side would be to add resource change listener in PositionTracker...

See also related issue / proposed workaround in LSP4E https://github.com/eclipse-lsp4e/lsp4e/pull/1501.

主要言語
Java
スター
124
フォーク
269
平均マージ
2日 5時間
マージ済み PR(30日)
65

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

eclipse-platform/eclipse.platform.ui のほかの issue

eclipse-platform/eclipse.platform.ui の issue をすべて見る

似ている issue

Java の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。