Path: csiph.com!3.eu.feeder.erje.net!feeder.erje.net!news.mb-net.net!open-news-network.org!.POSTED.120.232.197.178.dynamic.wless.lssmb00p-cgnat.res.cust.swisscom.ch!not-for-mail From: Thomas 'PointedEars' Lahn Newsgroups: comp.lang.javascript Subject: Highlighting text (was: How get windows FIND() to work?) Date: Thu, 06 Aug 2020 02:15:17 +0200 Organization: PointedEars Software (PES) Lines: 37 Message-ID: <1761438.CQOukoFCf9@PointedEars.de> References: <8635242.CDJkKcVGEf@PointedEars.de> <3d079cf5-4ac0-4a80-b45d-94a5fcd0eb88o@googlegroups.com> Reply-To: Thomas 'PointedEars' Lahn Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit Injection-Info: gwaiyur.mb-net.net; posting-host="120.232.197.178.dynamic.wless.lssmb00p-cgnat.res.cust.swisscom.ch:178.197.232.120"; logging-data="26751"; mail-complaints-to="abuse@open-news-network.org" User-Agent: KNode/4.14.10 Cancel-Lock: sha1:FRVWMGfxO/xRSDmIM+7JsHlAYWM= X-Face: %i>XG-yXR'\"2P/C_aO%~;2o~?g0pPKmbOw^=NT`tprDEf++D.m7"}HW6.#=U:?2GGctkL,f89@H46O$ASoW&?s}.k+&. On Wednesday, August 5, 2020 at 1:35:10 AM UTC-5, Thomas 'PointedEars' > Lahn wrote: >> Michael Haufe (TNO) wrote: >> > On Monday, August 3, 2020 at 9:13:41 PM UTC-5, Robert Baer wrote: >> >> BUT. the keyword does NOT get underlined or highlighted in any >> >> way. It would be particularly nice if all the keywords got ^^^^^^^^^^^^^^^^^^^^^^^ >> >> highlighted and the first keyword was presented on the screen ^^^^^^^^^^^ >> >> (think loong document and keyword was in middle). >> >> >> >> Help? >> > >> > Have you tried using the Selection API yet? >> > >> > >> >> Yes. It provides an interface to the selection *by the user*, so does >> the opposite thing that was asked for. > > Not only: > > OK, that can be useful in a different context. But it is a far cry from what was being asked for here. In fact, I found the implementation of all the approaches based on the document tree extremely tedious and error-prone, so I suggested the .innerHTML approach. -- PointedEars FAQ: | | Twitter: @PointedEars2 | Please do not cc me./Bitte keine Kopien per E-Mail.