Sort Text and Nudger for Q9

Discuss QuarkXTensions® and third-party XTensions® software

Sort Text and Nudger for Q9

Postby formerly Tony P » 26 Mar 2013, 04:50

There are a couple of Xtensions that I've used extensively with Quark 6, but I'm having trouble finding equivalents to use with Quark 9
(I'm assuming that versions for earlier versions of Quark simply won't work)

1)
Durrant Software's "Sort Text"
This puts selected paragraphs into alphabetical order, by first word(s) of text.


2)
Vison's Edge "Nudger"
This allows you to specify (and change) the default nudge distance for the arrow keys in a variety of measurements.
(Or does v9 perhaps have this facility built in?)

I've found both indispensible.

Does anyone have an ideas for Quark 9?

Thank you!
formerly Tony P
 
Posts: 136
Joined: 22 Dec 2008, 12:26

Sort Text and Nudger for Q9

Postby max.peter » 26 Mar 2013, 06:08

Hi Tony
For sorting text, if you can not get a XTension you can use a trick (I used it some time ago): copy each paragraph in a cell of a spreadsheet (MS Excel or some open source software like open.org), arrange the cells in the same column, then order the rows using "ascending" command (or equivalent). When you are done, export the spreadsheet as a text file, then import it in QXPress.
Instead using "Nudger" you can use a certain setting in the preferences: go to Edit>Preferences>Print Layout>Guides&Grid>Snap Distance. Insert whatever value you need and you are done.
Hope these can help you.
User avatar
max.peter
 
Posts: 1509
Joined: 11 Sep 2010, 12:35
Location: Romania

Sort Text and Nudger for Q9

Postby formerly Tony P » 26 Mar 2013, 20:59

Hello Max (or is it Peter? Never sure),

Thanks - yes I've done similar using Apple's 'Numbers' instead of Excel and just cut and paste the text back into Quark. It has slightly different rules for ordering non-alphabetic characters, but that isn't usually a big problem. I tried it also using the indexing functions in Quark but it was incredibly long-winded. It's just so much easier with an Xtension - just multiple clicks or drag to select the text and a keyboard shortcut to 'sort' and it's done!

I wonder if such a thing could be done with Applescript?

re: Nudge amounts I haven't got Quark 9 up and running yet - it'll go on a new machine and monitor I'm setting up; I'm wondering if this is more controllable in 9 - in Quark 6, the snap distance only seems to accept whole points as a measurement, and so it's not poss to set a metric measure when required (I've never been able to get guides to snap to the rulers when dragging them, which gets a bit tedious).

Thanks for your thoughts
formerly Tony P
 
Posts: 136
Joined: 22 Dec 2008, 12:26

Sort Text and Nudger for Q9

Postby Jean-Marie Schwartz » 27 Mar 2013, 22:58

formerly Tony P wrote:I wonder if such a thing could be done with Applescript?
Hi Tony! This is doable by AlleScript for sure. I used to have one script a long time ago then forgot about it when Sort Text.xnt came out. I should find my script though somewhere in the archives. The downside of it was that text formatting would get erased. It was back in v6 maybe so with v9 features such as Conditional Styles it might easy next to reformat the text if needed.
formerly Tony P wrote:Nudge amounts I haven't got Quark 9 up and running yet - it'll go on a new machine and monitor I'm setting up; I'm wondering if this is more controllable in 9 - in Quark 6, the snap distance only seems to accept whole points as a measurement, and so it's not poss to set a metric measure when required (I've never been able to get guides to snap to the rulers when dragging them, which gets a bit tedious).
As for nudge amounts, I think Badia FullMeasure features that. Just check their website.
And I'm not with you when you say "I've never been able to get guides to snap to the rulers when dragging them, which gets a bit tedious". What are you after exactly?
Jean-Marie Schwartz
 
Posts: 2483
Joined: 23 Nov 2004, 04:30

Sort Text and Nudger for Q9

Postby formerly Tony P » 28 Mar 2013, 00:25

Hello Jean-Marie and thanks for your response.

For my most regular uses of 'Sort Text' I was putting the items into alphabetical order before doing anything else so there wouldn't be much formatting to lose anyway, so that wouldn't be a problem for those jobs.

(I have been keeping lists and inventories as Quark docs too - mainly so I can make then look just as I want them, in terms of layout and typography - so I guess a Scripting solution wouldn't be ideal for those. Perhaps I should work harder at getting used to other applications for those jobs -- I even type my letters and invoices in Quark).

I'll take another look at "Full Measure" - thanks - there are probably other features in it I could use too.

Re. snapping to the rulers sorry, a separate issue to the Nudging when I drag guides across a document I cannot get them to snap to any whole numbers (or other values) whatever snap distance I set there. I'm sure this never used to be a problem, so I'm thinking maybe I've just forgotten how to do it (senility setting in!).
formerly Tony P
 
Posts: 136
Joined: 22 Dec 2008, 12:26

Sort Text and Nudger for Q9

Postby Jean-Marie Schwartz » 28 Mar 2013, 01:31

Can you give this code a shot?
(* This script will sort text stocked in the clipboard. Procedure is to select paragraphs in Quark. Run this script from the script menu. Pasting is automatic and in place. (Original Script by Tim Conner. Adaptation to QuarkXPress by Jean-Marie Schwartz :-)
*)


[b]tell application "QuarkXPress"
[b]activate
[b]delay 1
[b]select menu item "Copy" [b]of menu "Edition"
[b]end [b]tell




[b]set the clipboard to list_to_string(ASCII_Sort(string_to_list(class ktxt [b]of (([b]the clipboard as text) [b]as record), return)), return)


[b]tell application "QuarkXPress"
([b]delay 1) [b]activate
[b]select menu item "Paste" [b]of menu "Edition"
[b]end [b]tell




[b]on ASCII_Sort(my_list)
--from apple
[b]set [b]the index_list [b]to {}
[b]set [b]the sorted_list [b]to {}
[b]repeat ([b]the number [b]of items [b]in my_list) [b]times
set the low_item to ""repeat with i from 1 to (number of items in my_list)if i is not in the index_list thenset this_item to item i of my_list as textif the low_item is "" thenset the low_item to this_itemset the low_item_index to ielse if this_item comes before the low_item thenset the low_item to this_itemset the low_item_index to iend ifend ifend repeatset the end of sorted_list to the low_itemset the end of the index_list to the low_item_indexend repeatreturn the sorted_listend ASCII_Sorton snr(the_string, search_string, replace_string)return my list_to_string((my list_to_string(the_string, search_string)), replace_string)end snron list_to_string(the_list, the_delim)my atid(the_delim)set the_string to (every text item of the_list) as stringmy atid("")return the_stringend list_to_stringon string_to_list(the_string, the_delim)my atid(the_delim)set the_list to (every text item of the_string) as listmy atid("")return the_listend string_to_liston atid(the_delim)set AppleScript's text item delimiters to the_delimend atid
Jean-Marie Schwartz
 
Posts: 2483
Joined: 23 Nov 2004, 04:30

Sort Text and Nudger for Q9

Postby Jean-Marie Schwartz » 28 Mar 2013, 01:33

formerly Tony P wrote:Re. snapping to the rulers sorry, a separate issue to the Nudging when I drag guides across a document I cannot get them to snap to any whole numbers (or other values) whatever snap distance I set there. I'm sure this never used to be a problem, so I'm thinking maybe I've just forgotten how to do it (senility setting in!).
Guides won't snap to rulers or document edges! And if you want to place them more precisely, just zoom in at max. Snapping is only good for items to guides. Do you get it?
Jean-Marie Schwartz
 
Posts: 2483
Joined: 23 Nov 2004, 04:30

Sort Text and Nudger for Q9

Postby formerly Tony P » 02 Apr 2013, 00:00

Script for alphabetical order...
Hi Jean-Marie,
thanks - I'm travelling over the Easter break, but I've tried the script in Quark 6 (which I have on my lap top). I had a couple of different errors come up depending whether I ran it in the Applescript Editor or from Quark. I changed 'Edition' to 'Edit' (to suit the language of my menus?), then changed 'sorted_lists' to 'sorted_list' further on in the script and it then worked perfectly. I don't know if I'm losing something by changing that, but it wouldn't run to the end without.
Interestingly, if a number of groups of paragraphs are selected - each group separated by an extra hard return - the script will sort each group into alphabetical order (rather than combining them into one list): a potentially useful feature that the 'Sort text' xtension could not do.
The loss of formatting is an issue for some some jobs, but much of the time the script will be a great help.
I'll try this on Q9 as soon as I can. Thanks again!
formerly Tony P
 
Posts: 136
Joined: 22 Dec 2008, 12:26

Sort Text and Nudger for Q9

Postby formerly Tony P » 02 Apr 2013, 00:02

Guides / Nudging / 'Full measure"...
re: precise dragging of guides... not sure what has gone wrong for me - even up at 800% view guides are very reluctant to settle on exact values when dragging... this wasn't always the case so I'm guessing it's a glitch that's crept in to my set-up. I have had a couple of issues with my graphics tablet (which I use for everything) though, this might be where the problem lies as it's actually easier to place guides accurately (at a half-millimetre resolution) using the track-pad on the lap top, which can't be right...!
Badia Full Measure seems to offer a number of useful add-ons as well as Nudge amounts (doesn't say it's specifically Mountain Lion-compatable but I've asked Badia for clarification)
formerly Tony P
 
Posts: 136
Joined: 22 Dec 2008, 12:26

Sort Text and Nudger for Q9

Postby Jean-Marie Schwartz » 02 Apr 2013, 00:08

As for Guides, why don't you use the Guides palette? It offers you the possibility of setting grids, guides, colors, etc. with all the precision you're after. Or am I missing sth?
Jean-Marie Schwartz
 
Posts: 2483
Joined: 23 Nov 2004, 04:30

Next

Return to QuarkXPress 8, 9 & 10: XTensions modules

Who is online

Users browsing this forum: No registered users and 1 guest

cron