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 06-25-2014, 07:56 PM   #16
Sabardeyn
Guru
Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.Sabardeyn ought to be getting tired of karma fortunes by now.
 
Sabardeyn's Avatar
 
Posts: 644
Karma: 1242364
Join Date: May 2009
Location: The Right Coast
Device: PC (Calibre), Nexus 7 2013 (Moon+ Pro), HTC HD2/Leo (Freda)
Somewhat tangential: Chaley, thanks for the additional name display method. LASTNAME Firstname is sometimes preferred when dealing with Eastern authors, particularly with Manga.
Sabardeyn is offline   Reply With Quote
Old 06-25-2014, 10:02 PM   #17
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
Quote:
Originally Posted by myki View Post
As i said i didn't knew anything about GPM.
For me i feel more comfortable with program mode thanks to the use of variables.
And the writing is more vertical, when the normal mode is more horizontal.

I'm curious :
Is it possible to use variables in normal mode, and how ??
Is it possible to increase the size of the police inside the modele editor ?

Thanx for your help...

@chaley :
If i had your function, it would have been so easier for me to harmonize my authors the first time i built my database
As you can see in my example, I used two evaluation templates, for fn and ln, then simply added LN= before it. Simple assignment of variables.

Code:
variable=function();
Important things to remember:
  • every line or block must end with ";" to separate them -- not required for the last one.
  • Only the last block will be returned as the template value.
  • If you want to make use of multiple pieces of info, strcat() is your friend. It takes a list of comma-separated items (all those variables you created) and adds them together. Use this as the last block, to return a final value.

Last edited by eschwartz; 06-25-2014 at 10:07 PM.
eschwartz is offline   Reply With Quote
Advert
Old 06-26-2014, 02:17 AM   #18
myki
Zealot
myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.
 
Posts: 126
Karma: 20236
Join Date: May 2014
Device: Kinde PW v1, Kobo H2O, Onyx Boox T68
@eschwartz
Me and ";" are not friends, i always forget them
With my new knowledge thanks to you and chaley i'm going to improve my models !
I think that i will need your help again, for example how to know the last index number
But don't answer here, i'm going to create a new post for that
myki is offline   Reply With Quote
Old 06-26-2014, 03:52 AM   #19
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,339
Karma: 8012652
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Quote:
Originally Posted by myki View Post
As i said i didn't knew anything about GPM.
For me i feel more comfortable with program mode thanks to the use of variables.
And the writing is more vertical, when the normal mode is more horizontal.

I'm curious :
Is it possible to use variables in normal mode, and how ??
if by "normal mode" you mean Template Program Mode, then yes, but with difficulty. TPM is really an almost complete subset of GPM. The exceptions: in TPM:
  • you cannot use newlines. Everything must be on one line. Like GPM, statements are separated by semicolons
  • you should not use the { and } characters. They confuse the template parser (something tnat comes with python).
Quote:
Is it possible to increase the size of the police inside the modele editor ?
No, but that is a good idea. I have added a font size box to the template editor. It should be in the next calibre release.
Quote:

Thanx for your help...

@chaley :
If i had your function, it would have been so easier for me to harmonize my authors the first time i built my database
You are welcome.

Last edited by chaley; 06-26-2014 at 05:50 AM. Reason: correction
chaley is offline   Reply With Quote
Old 06-26-2014, 04:46 AM   #20
myki
Zealot
myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.myki can self-interpret dreams as they happen.
 
Posts: 126
Karma: 20236
Join Date: May 2014
Device: Kinde PW v1, Kobo H2O, Onyx Boox T68
@chaley
Yes i meant TPM (now i am more familiar with Calibre vocabulary)
I don't know for others, but for me GPM is much more instinctive (even if i never code).
It appears like a revelation to me, things that i believed impossible seem to be possible now
Now, i want to "play" with my data and make it act exactly how i want.
You have to know that if now i am more demanding with my datas and myself, and if i post more for help, that is entirely your fault (joke)
myki is offline   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Case Sensitive Regular Expression silentguy Calibre 5 05-11-2015 05:56 AM
Please help me with regular expression :help: Tatjana Library Management 2 05-30-2014 05:41 PM
Regular Expression Help Azhad Calibre 86 09-27-2011 02:37 PM
Regular expression help krendk Calibre 4 12-04-2010 04:32 PM
Help with the regular expression Dysonco Calibre 9 03-22-2010 10:45 PM


All times are GMT -4. The time now is 07:24 PM.


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