On Wed, 10 May 2000, Angus Leeming wrote:
> Allan> We also want to allow room for internationalized labels.
>
> Not sure what you mean here. Do you mean that the browsers should be wider as
> well as (Dekel's suggestion that they be) longer? I'm not sure that that is
> necessary, because the browsers seem to insert automatically a horizontal
> slide bar along their base should the keys be wider than the browser window.
I haven't looked at the .fd file but the problem with xforms is that is
doesn't resize automatically to fit longer labels in. That's the label
describing the keys or buttons not the actual keys themselves. Checkout
the po files for translations of "Citation" and other such words so you
get an idea of how long other languages labels will be.
> Allan> The citation and bibform should be separated into distinct dialogs. They
> Allan> can share the same definition but shouldn't expect to be able to swap
> Allan> labels on a shared dialog like we do at present. So starting a new
> Allan> fdesign is the right thing to do.
>
> I'd come to this conclusion also. I think that the citations are functionally
> and logically separate from the bibliography details and so will probably split
> insetbib.[Ch] into insetcite.[Ch] and insetbib.[Ch].
That's pretty much what I was hoping you would do.
> Allan> Remember that when you implement this you will almost certainly need to
> Allan> change the lyx file format to support the choice of citation style.
>
> You're ahead of me here too. I'm taking the attitude that small changes are
> best, so the first patch I submit will be of an improved citation dialog, but
> will not introduce support for natbib. Several issues are involved I think, so
> perhaps we can start the discussion of what here.
Step 0. Do all the coding of the new dialog in the gui-indep branch.
Okay, I know I haven't made a new one yet and it's not likely to get done
before I head off to melbourne. I'll take a couple of floppies of code
with me and do the update there and commit when I get to Paris or I might
try sending someone a patch or try to do it remotely on baywatch. Work on
a copy of the 1.1.5pre1 tree for now since that's what I'll be basing the
new branch on (unless 1.1.5pre2 is tagged and released by Friday
night). That way the patch should apply cleanly to the new gui-indep
tree.
> 1. I think choice of citation style should be made in the Layout->Document
> dialog. Two choices should be available
> standard LaTeX (ie, \cite)
> natbib (ie, choices of \citet, \citep etc)
We've had several requests for harvard.sty support also.
> 2. If the document is old and contains citations already then standard LaTeX
> will be the default choice for the citation style. If either of these
> requirements is not fullfilled then natbib will be the default.
Do all tex distros come with natbib? If not the default should probably
standard LaTeX.
> 3. The user can toggle between the two styles. Should citations already exist
> in the document then a warning message should popup in each case.
> standard LaTeX -> natbib
>
> Warning.
> All instances of \cite in this document will be changed to \citep
> These may be changed individually to suit requirements.
> Any instance of \usepackage{some citation package} in the LaTeX
> preamble should be removed.
> Ok Cancel
>
> natbib -> standard LaTeX
>
> Warning.
> Natbib citations are far more flexible than the LaTeX default.
> Information about the style of individual citations will be lost.
> Ok Cancel
looks good.
> 4. Layout Document should also contain/launch? a "Reference Options"
"contain". The document dialog should become a tabbed dialog in the
gui-indep cleanup.
> form. This would allow the user to choose such things as font, spacing
> etc of the References section, together with the style of the
> references. (Eg "plain" in standard LaTeX or "numbers" in natbib. It
> would also allow input of natbib's customization options etc.
I'm not sure what you mean by allowing the changing of fonts and sizes
etc. Surely that's a matter of choosing the right bibtex style (bst) for
use with BibTeX. For references hardcoded into the document the user will
be able to select all the entries and choose a font size to apply to them.
>
> Any suggestions/feedback?
Good ideas. Just remember that all the dialogs have to be made gui-indep
sometime. If you find yourself (this doesn't just apply to Angus either)
wanting to make changes to a particular dialog then you should start by
converting that dialog to be gui-indep. This should be considerably
easier after 1.1.5 when the gui-indep foundations are added to the main
trunk. Then at least you can start developing a patch against the main
tree, once you are happy with it, submit it, we put it in a branch of its
own where further cleanups/testing can be done and then merge it into the
main trunk once its proved to be a worthy replacement for existing dialog.
GUI-indep work is major open heart surgery on the LyX code -- every dialog
has bits of code scattered through at least 4 or 5 files but is also
(fortunately) reasonably independent of the rest of LyX. So putting a
patch to change a dialog into a separate branch is not punishment or me
being difficult it's part of the new development process and also an
easier opportunity to make sure one of those scattered bits of code hasn't
been left out.
Allan. (ARRae)