Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Firefox/editor/spellchecker/tests/   (Browser von der Mozilla Stiftung Version 136.0.1©)  Datei vom 10.2.2025 mit Größe 901 B image not shown  

Quelle  spellcheck.js   Sprache: JAVA

 
function isSpellingCheckOk(aEditor, aMisspelledWords, aTodo = false) {
  var selcon = aEditor.selectionController;
  var sel = selcon.getSelection(selcon.SELECTION_SPELLCHECK);
  var numWords = sel.rangeCount;

  if (aTodo) {
    todo_is(
      numWords,
      aMisspelledWords.length,
      "Correct number of misspellings and words."
    );
  } else {
    is(
      numWords,
      aMisspelledWords.length,
      "Correct number of misspellings and words."
    );
  }

  if (numWords !== aMisspelledWords.length) {
    return false;
  }

  for (var i = 0; i < numWords; ++i) {
    var word = String(sel.getRangeAt(i));
    if (aTodo) {
      todo_is(word, aMisspelledWords[i], "Misspelling is what we think it is.");
    } else {
      is(word, aMisspelledWords[i], "Misspelling is what we think it is.");
    }
    if (word !== aMisspelledWords[i]) {
      return false;
    }
  }
  return true;
}

Messung V0.5
C=94 H=95 G=94

¤ Dauer der Verarbeitung: 0.11 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.