Spell Checking Text Views

  • How do I set up spell checking of text views (NSTextView or
    subclass). The problem is with
    spellchecking embedded strings in source code. I need to make sure
    the spell checker sees
    only embedded strings.
    ------------------------------------------------------
    "Home is not where you are born, but where your heart finds peace" -
    Tommy Nordgren, "The dying old crone"
    <tommy.nordgren...>
  • On Oct 24, 2006, at 12:34 PM, Tommy Nordgren wrote:

    > How do I set up spell checking of text views (NSTextView or
    > subclass). The problem is with
    > spellchecking embedded strings in source code. I need to make sure
    > the spell checker sees
    > only embedded strings.

    Spellchecking driven from the menu or panel goes through the method -
    checkSpelling:, which can be overridden.  That method calls standard
    NSSpellChecker methods.  As-you-type spellchecking is not so easily
    overridden in Tiger and before; there will be more control available
    in Leopard.  You would probably need to drive it yourself.

    Douglas Davidson
  • On 24 okt 2006, at 21.45, Douglas Davidson wrote:

    >
    > On Oct 24, 2006, at 12:34 PM, Tommy Nordgren wrote:
    >
    >> How do I set up spell checking of text views (NSTextView or
    >> subclass). The problem is with
    >> spellchecking embedded strings in source code. I need to make sure
    >> the spell checker sees
    >> only embedded strings.
    >
    > Spellchecking driven from the menu or panel goes through the method
    > -checkSpelling:, which can be overridden.  That method calls
    > standard NSSpellChecker methods.  As-you-type spellchecking is not
    > so easily overridden in Tiger and before; there will be more
    > control available in Leopard.  You would probably need to drive it
    > yourself.
    >
    > Douglas Davidson
    >
    I've been checking through the API:s .  The easiest way to support
    strings in programming languages appears to be
    to create a custom NSTextView , that in it's turn creates/uses a
    custom NSTextStorage subclass.
    Now I have the problem of initializing a custom NSTextView subclass
    in interface builder.
    Is it possible, or do I have to create my view on the fly, in code?
    -------------------------------------
    This sig is dedicated to the advancement of Nuclear Power
    Tommy Nordgren
    <tommy.nordgren...>
  • On Nov 4, 2006, at 4:35 AM, Tommy Nordgren wrote:

    > I've been checking through the API:s .  The easiest way to support
    > strings in programming languages appears to be
    > to create a custom NSTextView , that in it's turn creates/uses a
    > custom NSTextStorage subclass.
    > Now I have the problem of initializing a custom NSTextView
    > subclass in interface builder.
    > Is it possible, or do I have to create my view on the fly, in code?

    You should be able to do it the same way you set any other view to a
    custom subclass in IB.

    Douglas Davidson
previous month october 2006 next month
MTWTFSS
            1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31          
Go to today