Loading ...
Sorry, an error occurred while loading the content.

Re: Activation keys

Expand Messages
  • dracorat
    Sounds good and I didn t really take offense to the situation. You know, I ll just leave this one be. I think he got his solution, so that s good. At any rate,
    Message 1 of 13 , Feb 12, 2008
    • 0 Attachment
      Sounds good and I didn't really take offense to the situation.

      You know, I'll just leave this one be. I think he got his solution, so
      that's good. At any rate, I am twice guilty of not fully testing my
      solution. I should know better - I am a programmer by trade. I blame
      laziness. That's it!

      --Keith

      --- In ntb-clips@yahoogroups.com, "Sheri" <silvermoonwoman@...> wrote:
      >
      > Hey, the OP thanked my by name but I'm not the one that commented on
      > your solution. :)
      >
      > FWIW, I appreciated the creativity of your solution even if it didn't
      > work out. This latest BRS doesn't work for me either, it doesn't
      > replace after typing e.g., didn;t. You would need to somehow
      > reposition the cursor to be just prior to the first letter of the word
      > before doing the ^!Replace. NoteTab doesn't do backward searches for
      > regex'es. Also "T" option (as in TRS) has no effect when using regex.
      >
      > From what I understand only .Net has experimental backward regex
      > searching and that uses own flavor of regex, not PCRE.
      >
      > For purposes of these AutoCorrect clips, it appears that you can have
      > capitalized and lower case versions of a clip if you want them.
      >
      > I really don't use this feature. The subject came up some years ago
      > and I made some potentially useful discoveries about ^%AR_KEY%, but
      > unfortuately I don't remember them and Yahoo search seems to be broken
      > for searching older parts of the archive.
      >
      > Regards,
      > Sheri
      >
    • Sheri
      ... Yahoo fixed the archive search (Yea!) Here s a working solution using your regex. Need two clips, one titled t and the other titled T . The capital
      Message 2 of 13 , Feb 13, 2008
      • 0 Attachment
        --- In ntb-clips@yahoogroups.com, "dracorat" <dracorat@...> wrote:
        >
        > Sounds good and I didn't really take offense to the situation.
        > You know, I'll just leave this one be. I think he got his
        > solution, so that's good. At any rate, I am twice guilty of not
        > fully testing my solution. I should know better - I am a
        > programmer by trade. I blame laziness. That's it!
        >
        > --Keith
        >

        Yahoo fixed the archive search (Yea!)

        Here's a working solution using your regex. Need two clips, one titled
        "t" and the other titled "T". The capital version just has a capital T
        in it and doesn't do any special processing. In the lower case
        version, the ^!Replace replaces all occurences in highlighted text,
        where the current line is highlighted. This happens only when the "t"
        was preceded by a ";". Otherwise it just inserts a lower case t. I've
        discovered that in recent versions, using hintinfo suppresses the
        display of highlights, so there are no momentary flashes. I also added
        ^%temp% (activation key) to the end of your replacement text.

        Here is the "t" clip:

        ^!Set %temp%=^%AR_KEY%
        ^!InsertText t
        ^!IfSame "^$GetChar(-1)$" ";" Next Else Finish
        ^!Sethintinfo working...
        ^!Select line
        ^!Set %AR_KEY%=""
        ^!REPLACE "\b(\w+)\;t\b" >> "$1\'t^%temp%" HRAS
        ^!Jump Select_End
        ^!Set hintinfo
        :Finish
        ^!Set %temp%=""
        ;end of clip

        Regards,
        Sheri
      • hsavage
        ... Sheri, Unless I misunderstood your directions I followed them with the t clip below. I created another clip and placed it above yours as follows; H= T
        Message 3 of 13 , Feb 13, 2008
        • 0 Attachment
          Sheri wrote:
          > Here's a working solution using your regex. Need two clips, one titled
          > "t" and the other titled "T". The capital version just has a capital T
          > in it and doesn't do any special processing. In the lower case
          > version, the ^!Replace replaces all occurrences in highlighted text,
          > where the current line is highlighted. This happens only when the "t"
          > was preceded by a ";". Otherwise it just inserts a lower case t. I've
          > discovered that in recent versions, using hintinfo suppresses the
          > display of highlights, so there are no momentary flashes. I also added
          > ^%temp% (activation key) to the end of your replacement text.
          >
          > Here is the "t" clip:
          >
          > Regards,
          > Sheri

          Sheri,

          Unless I misunderstood your directions I followed them with the 't' clip
          below. I created another clip and placed it above yours as follows;

          H="T"
          ^!InsertText T

          H="t"
          ^!Set %temp%=^%AR_KEY%
          ^!InsertText t
          ^!IfSame "^$GetChar(-1)$" ";" Next Else Finish
          ^!Sethintinfo working...
          ^!Select line
          ^!Set %AR_KEY%=""
          ^!REPLACE "\b(\w+)\;t\b" >> "$1\'t^%temp%" HRAS
          ^!Jump Select_End
          ^!Set hintinfo
          :Finish
          ^!Set %temp%=""
          ;end of clip

          I couldn't get it to correct the 'not' contractions.

          -------------------------

          Below are a set of 2 clips I've added to my AutoCorrect.clb. So far it
          handles any 'not contraction I've tested when mistakenly using a
          semi-colon with a minimum of distracting screen flicker. One can also
          type a lone 'T' in in upper or lower case and the result is a 'T' in the
          case you've typed.

          The uppercase 'T' clip must precede the lowercase 't' in the clipbook,
          as below, or the pair won't work correctly.


          H="T"
          ^!InsertText T

          H="t"
          ^!If "^$GetChar(-1)$" = ";" SWAP
          ^!If "^$GetChar(-1)$" = " " Next Else SWAP
          ^!InsertText t
          ^!GoTo End
          ;
          :SWAP
          ^!Set %rc%=^$GetRow$:^$Calc(^$GetCol$+2)$
          ^!MoveCursor -2
          ^!Replace "n;" >> "n't" S
          ^!SetCursor ^%rc%


          ·············································
          ºvº SL_044 created_2008.02.13_08.39.38

          Cooking 101:
          • Bringing Back Bacon, Eggs and Butter.
          € hrs € hsavage € pobox € com
        • Sheri
          Hi Harvey, ... Sorry about that. My actual working clips did not use the ^!InserText command (I changed it in the version provided without retesting). But
          Message 4 of 13 , Feb 13, 2008
          • 0 Attachment
            Hi Harvey,

            --- In ntb-clips@yahoogroups.com, hsavage <hsavage@...> wrote:
            > Sheri,
            >
            > Unless I misunderstood your directions I followed them with the
            > 't' clip below. I created another clip and placed it above yours
            > as follows;
            >
            > H="T"
            > ^!InsertText T
            >
            > H="t"
            > ^!Set %temp%=^%AR_KEY%
            > ^!InsertText t
            > ^!IfSame "^$GetChar(-1)$" ";" Next Else Finish
            > ^!Sethintinfo working...
            > ^!Select line
            > ^!Set %AR_KEY%=""
            > ^!REPLACE "\b(\w+)\;t\b" >> "$1\'t^%temp%" HRAS
            > ^!Jump Select_End
            > ^!Set hintinfo
            > :Finish
            > ^!Set %temp%=""
            > ;end of clip
            >
            > I couldn't get it to correct the 'not' contractions.
            >
            > -------------------------

            Sorry about that. My actual working clips did not use the ^!InserText
            command (I changed it in the version provided without retesting). But
            isn't that strange? The result for ^$GetChar(-1)$ varies if the clip
            uses the bare t instead of ^!InsertText t. My capitalized T clip
            followed my lower case one in the clip listing, but here that doesn't
            seem to matter. My capital T version has just a capital T in it, no
            ^!InsertText and no line break.

            >
            > Below are a set of 2 clips I've added to my AutoCorrect.clb. So
            > far it handles any 'not contraction I've tested when mistakenly
            > using a semi-colon with a minimum of distracting screen flicker.
            > One can also type a lone 'T' in in upper or lower case and the
            > result is a 'T' in the case you've typed.

            > The uppercase 'T' clip must precede the lowercase 't' in the
            > clipbook, as below, or the pair won't work correctly.

            >
            >
            > H="T"
            > ^!InsertText T
            >
            > H="t"
            > ^!If "^$GetChar(-1)$" = ";" SWAP
            > ^!If "^$GetChar(-1)$" = " " Next Else SWAP
            > ^!InsertText t
            > ^!GoTo End
            > ;
            > :SWAP
            > ^!Set %rc%=^$GetRow$:^$Calc(^$GetCol$+2)$
            > ^!MoveCursor -2
            > ^!Replace "n;" >> "n't" S
            > ^!SetCursor ^%rc%
            >
            >

            Good idea but you still need to somehow suppress the autocorrect
            behavior if the trigger wasn't a semicolon. Try typing for example:
            [t] or t.

            Regards,
            Sheri
          • Sheri
            There is also a difference in behavior of our clips between Light/Std vs Pro especially when the activation key is the enter key. Sheri
            Message 5 of 13 , Feb 13, 2008
            • 0 Attachment
              There is also a difference in behavior of our clips between Light/Std
              vs Pro especially when the activation key is the enter key.

              Sheri
            • hsavage
              ... Sheri, I m sure you re right about variations in clip handling between versions. I tend to use Pro exclusively for any text needs. I discovered by simply
              Message 6 of 13 , Feb 13, 2008
              • 0 Attachment
                Sheri wrote:
                >
                > Good idea but you still need to somehow suppress the autocorrect
                > behavior if the trigger wasn't a semicolon. Try typing for example:
                > [t] or t.
                >
                > Regards,
                > Sheri

                Sheri,

                I'm sure you're right about variations in clip handling between
                versions. I tend to use Pro exclusively for any text needs.

                I discovered by simply commenting out the second ^$GetChar()$ line the
                't' clip passes the test above and still corrects 'not' contractions
                when semicolons are used. The clip may have other faults but its worked
                with the tests I've done.

                H="T"
                ^!InsertText T

                H="t"
                ^!If "^$GetChar(-1)$" = ";" SWAP
                ; ^!If "^$GetChar(-1)$" = " " Next Else SWAP
                ^!InsertText t
                ^!GoTo End
                ;
                :SWAP
                ^!Set %rc%=^$GetRow$:^$Calc(^$GetCol$+2)$
                ^!MoveCursor -2
                ^!Replace "n;" >> "n't" S
                ^!SetCursor ^%rc%

                ·············································
                ºvº SL_044 created_2008.02.13_08.39.38

                Cooking 101:
                • Bringing Back Bacon, Eggs and Butter.
                € hrs € hsavage € pobox € com
              Your message has been successfully submitted and would be delivered to recipients shortly.