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-06-2018, 07:38 AM   #1
un_pogaz
Chalut o/
un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.
 
un_pogaz's Avatar
 
Posts: 439
Karma: 145424
Join Date: Dec 2017
Device: Kobo
Alternative booksize format (Ko)

Would it be possible to add an option to choose the format of the booksize between Mo, Ko , octet ?
I find the Mo much too big and given the size with it is not very precise.

There is an alternative solution by creating a column "Column built by other columns" and using this code:
program:format_number(divide(booksize(), 1000), '{0:.0f}')

The problem of this solution is that you only get the number and if you want to display it cleanly in the side panel, you have to create a second collone :
{#sizeko:|| Ko}

It’s all

Last edited by un_pogaz; 08-06-2018 at 11:42 AM.
un_pogaz is offline   Reply With Quote
Old 08-06-2018, 08:04 AM   #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,344
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
You can modify the program to output the suffix as well. Use general program mode, in which you can create arbitrarily powerful templates.
kovidgoyal is offline   Reply With Quote
Advert
Old 08-06-2018, 11:38 AM   #3
un_pogaz
Chalut o/
un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.
 
un_pogaz's Avatar
 
Posts: 439
Karma: 145424
Join Date: Dec 2017
Device: Kobo
Uh... How?
I copied/pasted the code from an old post. I don't fully understand it, so such a change is beyond my knowledge.
Thank.

Oh, and I saw that this kind of code in a custom collone could slow down the loading of a Library.
I'm not worried, but curious, to what extent?
un_pogaz is offline   Reply With Quote
Old 08-06-2018, 01:14 PM   #4
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,443
Karma: 8012886
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Also try the human_readable template function. I am not near a computer so I can't test, but I think the following does what you want.
Code:
program: human_readable(booksize())
chaley is offline   Reply With Quote
Old 08-06-2018, 02:20 PM   #5
un_pogaz
Chalut o/
un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.un_pogaz understands the importance of being earnest.
 
un_pogaz's Avatar
 
Posts: 439
Karma: 145424
Join Date: Dec 2017
Device: Kobo
Um, interesting but:
1) It gives me the size in Kb
2) It uses the suffix KB in the main display column "xxx KB".
I'm looking for something that comes close to the default column (no suffix with main display, yes for side panel)

But tahnks
un_pogaz is offline   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
how to choose which format is sent to reader? soondai Calibre 3 09-12-2010 11:51 PM
X to ePub....which format to choose? Belfaborac Calibre 7 05-28-2010 04:05 AM
Which format to choose John1997 Workshop 2 01-24-2010 03:32 PM
PRS-600 Which format to choose Sjonnie Sony Reader 28 01-22-2010 06:35 AM
For those that recieved shipping confirmation, which delivery option did you choose? Dragoro Amazon Kindle 14 02-27-2009 12:29 PM


All times are GMT -4. The time now is 03:16 AM.


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