Messages - Boxer Software [ switch to compact view ]

Pages: [1] 2 3 4 5next
1
Developer's Corner / Re: [BEST] Boxer Editor Scripting Thread
« on: March 30, 2008, 09:12 AM »
Hi Stefan,

I have thought i have seen this feature in Boxer, but didn't find it. So i have taken this to try my first Boxer script.

If you have a selection started, and then issue the Find command, there's an "Extend Selection" option on the Find dialog that should do what you like.

(Note: if the existing selection is of any size, the Scope will default to searching within the selection, so be sure to change the Scope to suit your need in order to enable the Extend Selection option.)


Best,

David Hamel
Boxer Software

2
Developer's Corner / Re: [BEST] Boxer Editor Scripting Thread
« on: March 25, 2008, 09:44 AM »
Hi Allen,

Thanks for jumping in.  I'm unfamiliar with ROT13, so I just worked from his pseudo-code.

Between our two macros, I think we've shown the concepts pretty well.

Best,

David Hamel
Boxer Software

3
Developer's Corner / Re: [BEST] Boxer Editor Scripting Thread
« on: March 25, 2008, 09:23 AM »
Stefan,

Here's a Boxer macro that will get the selected text, add 13 to each character within the selection, and then replace the selection with the new text:

Code: C [Select]
  1. macro newmacro()
  2. {
  3. string str;
  4. int i, len;
  5. int constant = 13;
  6.  
  7. // get the length of the selected text
  8. len = GetSelectionSize();
  9.  
  10. // make sure selection size won't
  11. // exceed maximum string size
  12. if (len >= 2048)
  13.         {
  14.         Message("Error", "Too much text is selected.");
  15.         return;
  16.         }
  17. else if (len == 0)
  18.         {
  19.         Message("Error", "No text is selected.");
  20.         return;
  21.         }
  22.  
  23. // get selection into 'str'    
  24. GetSelection(str);
  25.  
  26. // loop to process each character in 'str'
  27. for (i = 0; i < len; i++)
  28.         if (str[i] != '\r' && str[i] != '\n')
  29.                 str[i] += constant;
  30.        
  31. PutSelection(str);
  32. }

Best,

David Hamel
Boxer Software

4
Best Text Editor / Re: Boxer Text Editor
« on: January 08, 2008, 08:54 AM »
2. I saw there's project handling in Boxer. Is it possible (even through macro script) to jump to the definition of a function from the place of its call?

Now this is one I am willing to comment on. It's not related to the Project handling (in my mind), but I have already coded a "Jump to Declaration" command that allows for quick movement from a function reference (at the text cursor) to the point at which the function is declared.  This command will also be accessible via the macro language.

Since it's already done, I don't mind "promising" that one.  :)

Best,

David

http://www.boxersoftware.com

5
Best Text Editor / Re: Boxer Text Editor
« on: January 07, 2008, 04:00 PM »
I've been served well for many years by maintaining a policy of not giving promises or time estimates for new features.  To do otherwise can only lead to disappointment.  Rather, I encourage people to make a purchase decision based on the product they see, and not on the hope of what it might become.

Best,

David

http://www.boxersoftware.com

Pages: [1] 2 3 4 5next
Go to full version