Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > Workshop

Notices

Reply
 
Thread Tools Search this Thread
Old 06-07-2011, 08:13 AM   #1
ghostyjack
Guru
ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.ghostyjack ought to be getting tired of karma fortunes by now.
 
ghostyjack's Avatar
 
Posts: 718
Karma: 1085610
Join Date: Mar 2009
Location: Bristol, England
Device: PRS-T1, 1825PT, Galaxy Tab, One X, TF700T, Aura HD, Nexus 7
Macro Editing in Notepad++

Seeing as Notepad++ is free, I'd thought I'd have a go at trying to create some macros for it to speed up my format tidying up of my HTML files before I put them into Sigil to create my epubs.

Previously I used this tool to record the macros with the record macro function so I have the basic macro there in the shortcuts.xml file but when I look at it, there is a lot of extra line that I don't know what they are for.

Has anyone done this before and if so, do you have any hints on how I modify it?

I've attached my shortcuts.xml file to show you what I have already.

What the two macros I created do is replace all the single and double straight quotes to their curly equivalents. I'd like to supress all the notification boxes that pop up after each search and replace and have the macro finish with a message saying something like "Done".
Attached Files
File Type: xml shortcuts.xml (32.7 KB, 1641 views)
ghostyjack is offline   Reply With Quote
Old 07-26-2011, 04:50 PM   #2
SkookumPete
Enthusiast
SkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavensSkookumPete is a rising star in the heavens
 
Posts: 42
Karma: 13888
Join Date: Jun 2011
Device: Kindle
This is a late reply and you've probably solved the problem, but for the record...

The Notepad++ macro files are not very helpful unless you know what the command numbers mean, and I haven't seen documentation for this. The problem is that when you record a macro that opens a dialog box and then puts the input focus back on the text, all those actions are recorded. If you can figure out which commands are opening or switching focus to the search window, you can just delete them and do all the editing "silently."

My solution to the problem was to turn to Visual Studio, where macro files are much more easily understood and edited.

As far as curly quotes go, though, you're reinventing the wheel. Calibre will do this for you, and if you don't use Calibre, you can run the same Python script they use; google "SmartyPants".

cheers,
Peter
SkookumPete is offline   Reply With Quote
Advert
Old 02-10-2017, 02:17 PM   #3
P1h3r1e3d13
Munior Jember
P1h3r1e3d13 began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Feb 2017
Device: Kindle Voyage
Lightbulb Answer

For those coming from Google, the answer to the question is:
Code:
%AppData%\Notepad++\shortcuts.xml
Details here: SO: Where are the recorded macros stored in Notepad++?

The file is indeed pretty hard to parse, but I was able to make the fix I needed by staring at it long enough. Good luck!
P1h3r1e3d13 is offline   Reply With Quote
Old 02-10-2017, 03:30 PM   #4
Toxaris
Wizard
Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.
 
Toxaris's Avatar
 
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
Toxaris is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
word macro for editing needless paragraph marks excalibra Workshop 6 03-12-2011 10:35 AM
PRS-600 Notepad? prettyxreckless Sony Reader 4 08-27-2010 12:59 PM
Word Formatting Macro (Stingo's Macro) Stingo Sony Reader 75 08-24-2010 05:18 AM
Indexed notepad daudi iRex 29 02-26-2008 01:42 PM
Irex as a notepad? Goshzilla iRex 9 10-15-2007 08:02 AM


All times are GMT -4. The time now is 04:54 PM.


MobileRead.com is a privately owned, operated and funded community.