Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Calibre > Library Management

Notices

Reply
 
Thread Tools Search this Thread
Old 08-27-2020, 04:40 PM   #1
eater
Enthusiast
eater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it is
 
Posts: 49
Karma: 2002
Join Date: Feb 2018
Device: linux desktop
Improve or customize title case algorithm?

For example, I have a book titled "THE EFFECT OF pH, TEMPERATURE AND TIME ON CHEMICAL STABILITY"

I select "Change case > Title case" in the metadata editor.

The title is now "THE EFFECT OF pH, TEMPERATURE AND TIME ON CHEMICAL STABILITY".

I guess the lowercase p in pH is confusing Calibre?
eater is offline   Reply With Quote
Old 08-27-2020, 05:50 PM   #2
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 46,133
Karma: 168983734
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by eater View Post
For example, I have a book titled "THE EFFECT OF pH, TEMPERATURE AND TIME ON CHEMICAL STABILITY"

I select "Change case > Title case" in the metadata editor.

The title is now "THE EFFECT OF pH, TEMPERATURE AND TIME ON CHEMICAL STABILITY".

I guess the lowercase p in pH is confusing Calibre?
A bit weird. When I apply titlecase, your original title changes the 'THE' to 'The' leaving the rest of the title alone. If I convert to upper case, lower case or change pH to PH, then title case seems to work though you will have to manually correct Ph to pH after applying title case. Not sure if this edge case is worth worrying about.
DNSB is offline   Reply With Quote
Advert
Old 08-27-2020, 06:23 PM   #3
eater
Enthusiast
eater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it is
 
Posts: 49
Karma: 2002
Join Date: Feb 2018
Device: linux desktop
It's a pretty common situation for me, any time the title is mostly all caps with a few lowercase letters or words.
eater is offline   Reply With Quote
Old 08-27-2020, 08:04 PM   #4
hobnail
Running with scissors
hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.hobnail ought to be getting tired of karma fortunes by now.
 
Posts: 1,586
Karma: 14328510
Join Date: Nov 2019
Device: none
A regexp would probably do it for you; e.g., search/match <h2>(.)(.*)</h2> and replace with <h2>\1\L\2</h2>; that's how I do it in Sigil in one fell swoop. Then I go back and find the proper names and whatnot and upcase their first letter with Alt+U.
hobnail is offline   Reply With Quote
Old 08-27-2020, 08:32 PM   #5
eater
Enthusiast
eater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it iseater knows what time it is
 
Posts: 49
Karma: 2002
Join Date: Feb 2018
Device: linux desktop
Is there a way to apply a regexp to a book title in Calibre though? That's what I'm looking for.
eater is offline   Reply With Quote
Advert
Old 08-27-2020, 09:27 PM   #6
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,047
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
many CASE tools I have used, expect to start with Lowercase., so my routinne is:
Lower
Title
(touch up the odd usage)
theducks is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Shortcut to execute title case, lower case, etc. birkmaggs Library Management 2 10-28-2018 11:42 PM
Customize title bar encol Kindle Developer's Corner 15 08-13-2016 06:24 PM
Title Case Fbone Calibre 3 03-20-2015 11:05 PM
Regex for Title Case or Sentence case? Turtle91 Sigil 3 01-19-2013 01:36 PM
Title Case Dopedangel Calibre 6 10-16-2009 08:01 AM


All times are GMT -4. The time now is 04:53 AM.


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