Woodpig Posted March 15, 2023 Share Posted March 15, 2023 Hi, In Affinity Publisher I've imported the text of a Word doc, and all single and double quotes are straight, not smart. When I go to find and replace, the search cannot distinguish between opening and closing quotes - so FaR will replace everything with left (or right), but not both. Is there a way around this? Thanks, Gareth. _Th 1 Quote Link to comment Share on other sites More sharing options...
Old Bruce Posted March 15, 2023 Share Posted March 15, 2023 If you search for a space then " and you should find all opening quotes. Search for " and then a space and you should find all closing quotes. Find: \s" is for space then ". "\s is for " then space. Quote Mac Pro (Late 2013) Mac OS 12.7.2 Affinity Designer 2.3.1 | Affinity Photo 2.3.1 | Affinity Publisher 2.3.1 | Beta versions as they appear. I have never mastered color management, period, so I cannot help with that. Link to comment Share on other sites More sharing options...
walt.farrell Posted March 15, 2023 Share Posted March 15, 2023 2 minutes ago, Woodpig said: Is there a way around this? Only by careful construction of the Find strings, and multiple operations, and then careful inspection/review and manual fixup of errors at the end. So, for example: x'y where x and y are letters means the ' should be an apostrophe. x.' followed by a space usually means the ' is an ending single quote (and similarly for x." and similarly for ? or !) space followed by " is usually an opening quote mark and " followed by space is usually a closing quote (as mentioned by @Old Bruce) etc. (I may have a more complete list somewhere that I can try to find) It is error-prone, especially if the input text has any errors. But it can sometimes be fine-tuned based on intended and known usage patterns within the input text. Quote -- Walt Designer, Photo, and Publisher V1 and V2 at latest retail and beta releases PC: Desktop: Windows 11 Pro, version 23H2, 64GB memory, AMD Ryzen 9 5900 12-Core @ 3.00 GHz, NVIDIA GeForce RTX 3090 Laptop: Windows 11 Pro, version 23H2, 32GB memory, Intel Core i7-10750H @ 2.60GHz, Intel UHD Graphics Comet Lake GT2 and NVIDIA GeForce RTX 3070 Laptop GPU. iPad: iPad Pro M1, 12.9": iPadOS 17.3, Apple Pencil 2, Magic Keyboard Mac: 2023 M2 MacBook Air 15", 16GB memory, macOS Sonoma 14.3 Link to comment Share on other sites More sharing options...
Woodpig Posted March 15, 2023 Author Share Posted March 15, 2023 Thank you, both. That's a bit of a pain! I've just realised that I can actually change to smart quotes within Vellum, and then export a Word doc from there. I'm surprised that neither Affinity nor Mac Pages can do this. walt.farrell 1 Quote Link to comment Share on other sites More sharing options...
_Th Posted March 15, 2023 Share Posted March 15, 2023 In Word (PC, at least), find/replace for both single and double quotes will replace both types of straight quotes with the appropriate smart/curly quotes. (Assuming the spacing before/after each is correct.) If I remember correctly InDesign find/replace does the exact same thing. Would be extremely helpful if all Affinity apps would do the same. As often comes from my Department of Redundancy Department soapbox, it’s all about the workflow: Professional apps must understand the professional’s workflow and streamline it as much as possible. Every point of friction reduces user satisfaction, which of course hurts sales and industry adoption. Woodpig 1 Quote Link to comment Share on other sites More sharing options...
David in Яuislip Posted March 15, 2023 Share Posted March 15, 2023 Pretty straightforward, using regex "(?=(?:(?:[^"]*"){2})*[^"]*"[^"]*$) will find leading straight quotes so put that in the find box Make a dummy word like "dummy" with smart quotes, copy the opening quote into the Replace box and click replace all Now put a straight quote into the find box, copy the closing quote from dummy" into the Replace box and click replace all I wish I'd thought of this but it's herehttps://stackoverflow.com/questions/71029975/regex-to-replace-regular-quotes-with-curly-quotes Woodpig, laurent32 and walt.farrell 3 Quote Microsoft Windows 11 Home, Intel i7-1360P 2.20 GHz, 32 GB RAM, 1TB SSD, Intel Iris Xe Affinity Photo - 24/05/20, Affinity Publisher - 06/12/20, KTM Superduke - 27/09/10 Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.