Geen cache-versie.

Caching uitgeschakeld. Standaardinstelling voor deze pagina:ingeschakeld (code LNG204)
Als het scherm te langzaam is, kunt u de gebruikersmodus uitschakelen om de cacheversie te bekijken.
javax.swing.text

Class StyledEditorKit

  • All Implemented Interfaces:
    Serializable, Cloneable
    Direct Known Subclasses:
    HTMLEditorKit, RTFEditorKit

    public class StyledEditorKit
    extends DefaultEditorKit
    This is the set of things needed by a text component to be a reasonably functioning editor for some type of text document. This implementation provides a default implementation which treats text as styled text and provides a minimal set of actions for editing styled text.
    • Constructor Detail

      • StyledEditorKit

        public StyledEditorKit()
        Creates a new EditorKit used for styled documents.
    • Method Detail

      • getInputAttributes

        public MutableAttributeSet getInputAttributes()
        Gets the input attributes for the pane. When the caret moves and there is no selection, the input attributes are automatically mutated to reflect the character attributes of the current caret location. The styled editing actions use the input attributes to carry out their actions.
        Returns:
        the attribute set
      • getCharacterAttributeRun

        public Element getCharacterAttributeRun()
        Fetches the element representing the current run of character attributes for the caret.
        Returns:
        the element
      • getActions

        public Action[] getActions()
        Fetches the command list for the editor. This is the list of commands supported by the superclass augmented by the collection of commands defined locally for style operations.
        Overrides:
        getActions in class DefaultEditorKit
        Returns:
        the command list
      • createDefaultDocument

        public Document createDefaultDocument()
        Creates an uninitialized text storage model that is appropriate for this type of editor.
        Overrides:
        createDefaultDocument in class DefaultEditorKit
        Returns:
        the model
      • install

        public void install(JEditorPane c)
        Called when the kit is being installed into a JEditorPane.
        Overrides:
        install in class EditorKit
        Parameters:
        c - the JEditorPane
      • deinstall

        public void deinstall(JEditorPane c)
        Called when the kit is being removed from the JEditorPane. This is used to unregister any listeners that were attached.
        Overrides:
        deinstall in class EditorKit
        Parameters:
        c - the JEditorPane
      • getViewFactory

        public ViewFactory getViewFactory()
        Fetches a factory that is suitable for producing views of any models that are produced by this kit. This is implemented to return View implementations for the following kinds of elements:
        • AbstractDocument.ContentElementName
        • AbstractDocument.ParagraphElementName
        • AbstractDocument.SectionElementName
        • StyleConstants.ComponentElementName
        • StyleConstants.IconElementName
        Overrides:
        getViewFactory in class DefaultEditorKit
        Returns:
        the factory
      • createInputAttributes

        protected void createInputAttributes(Element element,
                                 MutableAttributeSet set)
        Copies the key/values in elements AttributeSet into set. This does not copy component, icon, or element names attributes. Subclasses may wish to refine what is and what isn't copied here. But be sure to first remove all the attributes that are in set.

        This is called anytime the caret moves over a different location.

Nederlandse vertaling

U hebt gevraagd om deze site in het Nederlands te bezoeken. Voor nu wordt alleen de interface vertaald, maar nog niet alle inhoud.

Als je me wilt helpen met vertalingen, is je bijdrage welkom. Het enige dat u hoeft te doen, is u op de site registreren en mij een bericht sturen waarin u wordt gevraagd om u toe te voegen aan de groep vertalers, zodat u de gewenste pagina's kunt vertalen. Een link onderaan elke vertaalde pagina geeft aan dat u de vertaler bent en heeft een link naar uw profiel.

Bij voorbaat dank.

Document heeft de 11/06/2005 gemaakt, de laatste keer de 04/03/2020 gewijzigd
Bron van het afgedrukte document:https://www.gaudry.be/nl/java-api-rf-javax/swing/text/stylededitorkit.html

De infobrol is een persoonlijke site waarvan de inhoud uitsluitend mijn verantwoordelijkheid is. De tekst is beschikbaar onder CreativeCommons-licentie (BY-NC-SA). Meer info op de gebruiksvoorwaarden en de auteur.

Referenties

  1. Bekijk - html-document Taal van het document:fr Manuel PHP : https://docs.oracle.com

Deze verwijzingen en links verwijzen naar documenten die geraadpleegd zijn tijdens het schrijven van deze pagina, of die aanvullende informatie kunnen geven, maar de auteurs van deze bronnen kunnen niet verantwoordelijk worden gehouden voor de inhoud van deze pagina.
De auteur Deze site is als enige verantwoordelijk voor de manier waarop de verschillende concepten, en de vrijheden die met de referentiewerken worden genomen, hier worden gepresenteerd. Vergeet niet dat u meerdere broninformatie moet doorgeven om het risico op fouten te verkleinen.

Inhoudsopgave Haut