Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Editor

Notices

Reply
 
Thread Tools Search this Thread
Old 11-28-2014, 05:59 PM   #1
phossler
Wizard
phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.
 
Posts: 1,087
Karma: 447222
Join Date: Jan 2009
Location: Valley Forge, PA, USA
Device: Kindle Paperwhite
Spell Check and Change Case question/issue?

Question as to the way Change Case works

#1. Selected all lower case text between tags and applied each of the 5 possible operations and that seems to work as expected

#2. Selected mixEDcaSE words between tags and the 5 operations only seem to catch some of the selected text

#3. Selected all lower case text but INCLUDING the tags and applied each of the 5 possible operations and it seems that the tags are included in the operation. I.e. uppercasing <p>cat</p> gives <P>CAT</P>.

Spoiler:


<p>before -- All 5 were in lower case</p>
<p>upper case upper case</p>
<p>lower case lower case</p>
<p>swap case swap case</p>
<p>title case title case</p>
<p>capitalize capitalize</p>

<p>#1 -- select between tags and after each operation</p>
<p>UPPER CASE UPPER CASE</p>
<p>lower case lower case</p>
<p>SWAP CASE SWAP CASE</p>
<p>Title Case Title Case</p>
<p>Capitalize capitalize</p>

<p> start with 'aaaa bbbb CCCC dddd eeeEEE FFFfff'</p>
<p>#2 - select between tags and apply each of the 5</p>
<p>AAAA bbbb CCCC dddd eeeEEE FFFfff</p>
<p>aaaa bbbb CCCC dddd eeeeee FFFfff</p>
<p>aaaa bbbb CCCC dddd eeeEEE fffFFF</p>
<p>aaaa Bbbb CCCC dddd eeeEEE FFFfff</p>
<p>aaaa Bbbb CCCC dddd eeeEEE FFFfff</p>


<p>#3 - select text AND tags and apply each of the 5</p>
<P>UPPER CASE UPPER CASE</P>
<p>lower case lower case</p>
<P>SWAP CASE SWAP CASE</P>
<p>title Case Title Case</p>
<p>capitalize capitalize</p>

Last edited by phossler; 11-29-2014 at 10:26 AM.
phossler is offline   Reply With Quote
Old 11-28-2014, 09:12 PM   #2
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
If you want the operation to apply to only parts of the matched text, surround those parts by brackets in your find expression. See the example in the manual.
kovidgoyal is offline   Reply With Quote
Advert
Old 11-28-2014, 09:24 PM   #3
phossler
Wizard
phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.
 
Posts: 1,087
Karma: 447222
Join Date: Jan 2009
Location: Valley Forge, PA, USA
Device: Kindle Paperwhite
Sorry -- I wasn't very clear.

I select text and then right-click to use the Change Case menu.

It has the 5 operations that I tried

Doing it that way, I don't think I would have a Find expression

I really did look in the manual for using Change Case, but didn't see it
Attached Thumbnails
Click image for larger version

Name:	Capture.JPG
Views:	227
Size:	75.6 KB
ID:	131722  
phossler is offline   Reply With Quote
Old 11-28-2014, 09:43 PM   #4
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Then if you dont want it to apply to the content in tags, dont select the tags. It will apply to whatever you have selected.
kovidgoyal is offline   Reply With Quote
Old 11-28-2014, 10:20 PM   #5
phossler
Wizard
phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.
 
Posts: 1,087
Karma: 447222
Join Date: Jan 2009
Location: Valley Forge, PA, USA
Device: Kindle Paperwhite
1. I just figured that tags would by bypassed.

2. The real issue seems to be that if the text is mixed case (start) after operations like Upper Case the text is not all upper case like I would expect (end)

Code:
<body>
  <p> start with 'aaaa bbbb CCCC dddd eeeEEE FFFfff'</p>
  <p> end with after UPPER CASE 'AAAA bbbb CCCC dddd eeeEEE FFFfff xxxx'</p>
</body>

Last edited by phossler; 11-28-2014 at 10:44 PM.
phossler is offline   Reply With Quote
Advert
Old 11-28-2014, 10:25 PM   #6
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
I cannot replace that, selecting mixed case text makes it all uppercase. Note that when you right click the editor might automatically adjust your selection, look at what is selected when the right click menu pops up
kovidgoyal is offline   Reply With Quote
Old 11-28-2014, 11:05 PM   #7
phossler
Wizard
phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.
 
Posts: 1,087
Karma: 447222
Join Date: Jan 2009
Location: Valley Forge, PA, USA
Device: Kindle Paperwhite
Change Case and Spell Check

You are right -- the editor seems to be adjusting my selected text based on the fact that the second case below seems to be in mixed case

In both cases I selected the text with the mouse from right to left

In the first the "nice text in one case" remained selected after a right click
In the second only the "aaaa" remained selected after a right click


Original --

Code:
<body>
    <p>original = nice text in one case</p>
    <p>after     = nice text in one case</p>

    <p>original = aaaa bbbb CCCC dddd eeeEEE FFFfff</p>
    <p>after    =  aaaa bbbb CCCC dddd eeeEEE FFFfff</p>
  
</body>

After UPPER CASE

Code:
<body>
    <p>original = nice text in one case</p>
    <p>after     = NICE TEXT IN ONE CASE</p>

    <p>original = aaaa bbbb CCCC dddd eeeEEE FFFfff</p>
    <p>after    = AAAA bbbb CCCC dddd eeeEEE FFFfff</p>
  
</body>
Is the editor supposed to do that, or is there a setting I'm missing?

Last edited by phossler; 11-29-2014 at 10:25 AM. Reason: Did some more testing
phossler is offline   Reply With Quote
Old 11-29-2014, 10:24 AM   #8
phossler
Wizard
phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.
 
Posts: 1,087
Karma: 447222
Join Date: Jan 2009
Location: Valley Forge, PA, USA
Device: Kindle Paperwhite
Update -- what seems to make the difference for the editor adjusting the selection is the right-click spell checking kicking for the nonsense text I was using to test. If I use ALL real words in mixed case ...

Code:
  <p>original = cat doG bird hoUSE Car boat TRAIN</p>
  <p>after    = CAT DOG BIRD HOUSE CAR BOAT TRAIN</p>
... then the Change Case works


But what was/is confusing me was the sensitivity of the editor's changing the selection depending on the cursor position after selecting the test.

Below when I selected the text between the tags, and right click on a real word (e.g. doG) all text remains selected and no spell check correction pops up and Change Case happens as expected. However if I select a word not in the dictionary (even though it should be ) only that word is selected since the spell check popup seems to take precedence and Change Case is applied to only the single selected word

Code:
  <p>after    = cat doG bird hoUSE Car boat TRAIN KovidGoyalIsGREAT</p>
phossler is offline   Reply With Quote
Old 11-29-2014, 11:26 AM   #9
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Simply right click outside the selection and it will not be auto-adjusted at all. The selection is auto-adjusted only when the cursor is in a word marked as being misspelled, this allows for simple replacement of misspelled words by right clicking on them.

Last edited by kovidgoyal; 11-29-2014 at 11:31 AM.
kovidgoyal is offline   Reply With Quote
Old 11-29-2014, 08:41 PM   #10
phossler
Wizard
phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.phossler ought to be getting tired of karma fortunes by now.
 
Posts: 1,087
Karma: 447222
Join Date: Jan 2009
Location: Valley Forge, PA, USA
Device: Kindle Paperwhite
Boy, am I embarrassed

Never occurred to me to select the text and not right click in the selection
phossler is offline   Reply With Quote
Old 11-29-2014, 10:23 PM   #11
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Nonetheless, I have changed the editor to not alter the current selection when right-clicking on a mis-spelled word. Simple replace of the mis-spelled word will still work, but people will not be confused by the changed selection.
kovidgoyal is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
KB Shortcuts for Change Case? phossler Editor 12 08-15-2014 05:20 AM
Change case tool ZoeRochelle Editor 12 04-04-2014 06:55 PM
Language change issue Shivam Sony Reader Dev Corner 1 12-26-2012 04:34 PM
Troubleshooting New Kindle Non-Touch - Case Issue? apaximander Amazon Kindle 3 01-31-2012 03:14 PM
Folder case change skells Calibre 3 05-17-2011 02:24 PM


All times are GMT -4. The time now is 01:20 PM.


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