Re: margin figure's label counter
Sorry! Fixing a typo: Float Type marginfigure #<--, not "figure" GuiName MarginFigure AllowsWide0 AllowsSideways0 Placement none Extension lof NumberWithin figure Style plain ListName "List of Figures" IsPredefined 1 UsesFloatPkg 0 RefPrefix fig End --- Original Message --- On Saturday, July 16th, 2022 at 9:07 PM, Ehud Behar via lyx-users wrote: > Sure. I wrote a short version to de-clutter the question. > > Actually I am writing the lyx code in local layout, but in the future it will > be added by means of a module file. > > Here is the complete Style declation: > > Float > Type figure > GuiName MarginFigure > AllowsWide 0 > AllowsSideways 0 > Placement none > Extension lof > NumberWithin figure > Style plain > ListName "List of Figures" > IsPredefined 1 > UsesFloatPkg 0 > RefPrefix fig > End > > Thanks > > --- Original Message --- > On Saturday, July 16th, 2022 at 9:04 PM, Jean-Marc Lasgouttes > lasgouttes.lyx@free.fr wrote: > > > > > Le 16/07/2022 à 22:00, Ehud Behar via lyx-users a écrit : > > > > > No, it completely removes and overrides the existing figure from > > > stdfloats.inc. I want to have both figure and margin figure. > > > > I would need a complete example to proceed. The best is to create a > > document and add your layout code in Document>Settings|Local layout. > > > > JMarc > > -- > > lyx-users mailing list > > lyx-users@lists.lyx.org > > http://lists.lyx.org/mailman/listinfo/lyx-users > > -- > lyx-users mailing list > lyx-users@lists.lyx.org > http://lists.lyx.org/mailman/listinfo/lyx-users -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: margin figure's label counter
Sure. I wrote a short version to de-clutter the question. Actually I am writing the lyx code in local layout, but in the future it will be added by means of a module file. Here is the complete Style declation: Float Type figure GuiName MarginFigure AllowsWide0 AllowsSideways0 Placement none Extension lof NumberWithin figure Style plain ListName "List of Figures" IsPredefined 1 UsesFloatPkg 0 RefPrefix fig End Thanks --- Original Message --- On Saturday, July 16th, 2022 at 9:04 PM, Jean-Marc Lasgouttes wrote: > Le 16/07/2022 à 22:00, Ehud Behar via lyx-users a écrit : > > > No, it completely removes and overrides the existing figure from > > stdfloats.inc. I want to have both figure and margin figure. > > > I would need a complete example to proceed. The best is to create a > document and add your layout code in Document>Settings|Local layout. > > > JMarc > -- > lyx-users mailing list > lyx-users@lists.lyx.org > http://lists.lyx.org/mailman/listinfo/lyx-users -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: margin figure's label counter
Le 16/07/2022 à 22:00, Ehud Behar via lyx-users a écrit : No, it completely removes and overrides the existing figure from stdfloats.inc. I want to have *both* figure and margin figure. I would need a complete example to proceed. The best is to create a document and add your layout code in Document>Settings|Local layout. JMarc -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: margin figure's label counter
No, it completely removes and overrides the existing figure from stdfloats.inc. I want to have *both* figure and margin figure. --- Original Message --- On Saturday, July 16th, 2022 at 8:51 PM, Jean-Marc Lasgouttes wrote: > Le 16/07/2022 à 21:47, Jean-Marc Lasgouttes a écrit : > > > Hello, > > > > Did you try "NumberWithin none" like other floats in layouts/stdfloats.inc? > > > I would also use "Type figure" to convey that your marginfigure is just > a figure. > > JMarc > -- > lyx-users mailing list > lyx-users@lists.lyx.org > http://lists.lyx.org/mailman/listinfo/lyx-users -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: margin figure's label counter
Just tried it. It effectively sets the new Style a counter of its own, indifferent to what is the chapter or section or any other parent counter. That is: Margin figure 1, margin figure 2 in chapter 1, margin figure 3 in chapter 2 etc. --- Original Message --- On Saturday, July 16th, 2022 at 8:47 PM, Jean-Marc Lasgouttes wrote: > Le 16/07/2022 à 21:03, Ehud Behar via lyx-users a écrit : > > > I want to define a new float in my document - margin figure. > > > > I defined a new float using a module file with a Style: > > > > Float > > Type marginfigure > > GuiName MarginFigure > > NumberWithin figure # < > > RefPrefix fig > > more commands etc. > > End > > > > The document class is book, and inside chapter 1, as you can see in the > > attached image, I inserted a regular figure, followed by a margin > > figure. The margin figure counter in the editor is 1.1.1, since it is in > > chapter one, and it inherited the first number inside the figure counter. > > > > I want the margin figure to have the label 1.2 (which logically makes > > more sense if you treat figure and marginfigure on an equal footing). > > > > What amendments should I make to the Style to get it changed the way I want? > > > Hello, > > Did you try "NumberWithin none" like other floats in layouts/stdfloats.inc? > > To be frank, I thought I knoew how this stuff wors, but it seems that > many things happened since that time :) > > JMarc > -- > lyx-users mailing list > lyx-users@lists.lyx.org > http://lists.lyx.org/mailman/listinfo/lyx-users -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: margin figure's label counter
Le 16/07/2022 à 21:47, Jean-Marc Lasgouttes a écrit : Hello, Did you try "NumberWithin none" like other floats in layouts/stdfloats.inc? I would also use "Type figure" to convey that your marginfigure is just a figure. JMarc -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
Re: margin figure's label counter
Le 16/07/2022 à 21:03, Ehud Behar via lyx-users a écrit : I want to define a new float in my document - margin figure. I defined a new float using a module file with a Style: Float Type marginfigure GuiName MarginFigure NumberWithin figure # < RefPrefix fig more commands etc. End The document class is book, and inside chapter 1, as you can see in the attached image, I inserted a regular figure, followed by a margin figure. The margin figure counter in the editor is 1.1.1, since it is in chapter one, and it inherited the first number inside the figure counter. I want the margin figure to have the label 1.2 (which logically makes more sense if you treat figure and marginfigure on an equal footing). What amendments should I make to the Style to get it changed the way I want? Hello, Did you try "NumberWithin none" like other floats in layouts/stdfloats.inc? To be frank, I thought I knoew how this stuff wors, but it seems that many things happened since that time :) JMarc -- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users
margin figure's label counter
I want to define a new float in my document - margin figure. I defined a new float using a module file with a Style: Float Type marginfigure GuiName MarginFigure NumberWithin figure # < RefPrefix fig more commands etc. End The document class is book, and inside chapter 1, as you can see in the attached image, I inserted a regular figure, followed by a margin figure. The margin figure counter in the editor is 1.1.1, since it is in chapter one, and it inherited the first number inside the figure counter. I want the margin figure to have the label 1.2 (which logically makes more sense if you treat figure and marginfigure on an equal footing). What amendments should I make to the Style to get it changed the way I want?-- lyx-users mailing list lyx-users@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-users