Re: Shaded note = Colored Note???
why is a shaded note called shaded? AFAICS, a shaded note is in fact a colored note both on screen and in LaTeX output! I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. Here comes a first proposal that cleans up the code. Personally, I think that we call too many things a note. At least, we are supposed to be consistent (internally externally) with this patch. What is missing is a lyx2lyx converter that converts the two former note types (Note Shaded) to \begin_inset Note LyXInternal and \begin_inset Note Colored Any volunteer? Any comments? Michael Index: src/Color.h === --- src/Color.h (Revision 18810) +++ src/Color.h (Arbeitskopie) @@ -85,20 +85,20 @@ /// The color used for previews preview, - /// Text color for notes - note, - /// Background color of notes - notebg, - /// Text color for comments - comment, - /// Background color of comments - commentbg, - /// Text color for greyedout inset - greyedout, - /// Background color of greyedout inset - greyedoutbg, - /// Shaded box background - shadedbg, + /// Text color for lyx-internal notes + notelyxinternal, + /// Background color of lyx-internal notes + notelyxinternalbg, + /// Text color for tex comments + notecomment, + /// Background color of tex comments + notecommentbg, + /// Text color for greyedout notes + notegreyedout, + /// Background color of greyedout notes + notegreyedoutbg, + /// Background color of colored notes + notecoloredbg, /// Color for the depth bars in the margin depthbar, Index: src/insets/InsetNomencl.cpp === --- src/insets/InsetNomencl.cpp (Revision 18810) +++ src/insets/InsetNomencl.cpp (Arbeitskopie) @@ -97,7 +97,7 @@ newlines += static_castInsetNomencl const (*it).docbookGlossary(os); ++it; } else if(it-lyxCode() == Inset::NOTE_CODE - static_castInsetNote const (*it).params().type == InsetNoteParams::Note) { + static_castInsetNote const (*it).params().type == InsetNoteParams::LyXInternal) { // Don't output anything nested in note insets size_t const depth = it.depth(); ++it; Index: src/insets/InsetNote.cpp === --- src/insets/InsetNote.cpp (Revision 18810) +++ src/insets/InsetNote.cpp (Arbeitskopie) @@ -50,22 +50,22 @@ NoteTranslator const init_notetranslator() { - NoteTranslator translator(Note, InsetNoteParams::Note); + NoteTranslator translator(LyXInternal, InsetNoteParams::LyXInternal); translator.addPair(Comment, InsetNoteParams::Comment); translator.addPair(Greyedout, InsetNoteParams::Greyedout); translator.addPair(Framed, InsetNoteParams::Framed); - translator.addPair(Shaded, InsetNoteParams::Shaded); + translator.addPair(Colored, InsetNoteParams::Colored); return translator; } NoteTranslatorLoc const init_notetranslator_loc() { - NoteTranslatorLoc translator(_(Note), InsetNoteParams::Note); + NoteTranslatorLoc translator(_(LyX-internal), InsetNoteParams::LyXInternal); translator.addPair(_(Comment), InsetNoteParams::Comment); translator.addPair(_(Greyed out), InsetNoteParams::Greyedout); translator.addPair(_(Framed), InsetNoteParams::Framed); - translator.addPair(_(Shaded), InsetNoteParams::Shaded); + translator.addPair(_(Colored), InsetNoteParams::Colored); return translator; } @@ -89,7 +89,7 @@ InsetNoteParams::InsetNoteParams() - : type(Note) + : type(LyXInternal) {} @@ -152,7 +152,7 @@ { switch (params_.type) { case InsetNoteParams::Framed: - case InsetNoteParams::Shaded: + case InsetNoteParams::Colored: return AlignLeft; default: return Inline; @@ -186,20 +186,20 @@ Color_color c; switch (params_.type) { - case InsetNoteParams::Note: - c = Color::note; + case InsetNoteParams::LyXInternal: + c = Color::notelyxinternal; break; case InsetNoteParams::Comment: - c = Color::comment; + c = Color::notecomment; break; case InsetNoteParams::Greyedout: - c = Color::greyedout; + c = Color::notegreyedout; break; case InsetNoteParams::Framed: - c = Color::greyedout; + c = Color::notegreyedout; break; - case InsetNoteParams::Shaded: - c = Color::greyedout; + case InsetNoteParams::Colored: + c = Color::notegreyedout; break; } font.setColor(c); @@ -211,20 +211,20 @@ { Color_color c; switch (params_.type) { - case InsetNoteParams::Note: - c = Color::notebg; + case InsetNoteParams::LyXInternal: + c = Color::notelyxinternalbg; break; case InsetNoteParams::Comment: - c = Color::commentbg; + c = Color::notecommentbg; break; case InsetNoteParams::Greyedout: - c = Color::greyedoutbg; + c = Color::notegreyedoutbg; break; case InsetNoteParams::Framed: - c = Color::greyedoutbg; + c = Color::notegreyedoutbg; break; - case InsetNoteParams::Shaded: - c = Color::shadedbg; + case
Re: Shaded note = Colored Note???
On Sun, Jun 17, 2007 at 11:19:37AM +0200, Michael Gerz wrote: Here comes a first proposal that cleans up the code. Personally, I think that we call too many things a note. At least, we are supposed to be consistent (internally externally) with this patch. What is missing is a lyx2lyx converter that converts the two former note types (Note Shaded) to \begin_inset Note LyXInternal and \begin_inset Note Colored Any volunteer? Any comments? Just a comment. With this patch you are going to break compatibility with existing preferences and lyxrc.dist files. Please, don't do that. -1 -- Enrico
Re: Shaded note = Colored Note???
Also, we are supposed to focus on critical bugs now. -1 Bo
Re: Shaded note => Colored Note???
why is a "shaded note" called "shaded"? AFAICS, a shaded note is in fact a colored note both on screen and in LaTeX output! I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. Here comes a first proposal that cleans up the code. Personally, I think that we call too many things a note. At least, we are supposed to be consistent (internally & externally) with this patch. What is missing is a lyx2lyx converter that converts the two former note types (Note & Shaded) to \begin_inset Note LyXInternal and \begin_inset Note Colored Any volunteer? Any comments? Michael Index: src/Color.h === --- src/Color.h (Revision 18810) +++ src/Color.h (Arbeitskopie) @@ -85,20 +85,20 @@ /// The color used for previews preview, - /// Text color for notes - note, - /// Background color of notes - notebg, - /// Text color for comments - comment, - /// Background color of comments - commentbg, - /// Text color for greyedout inset - greyedout, - /// Background color of greyedout inset - greyedoutbg, - /// Shaded box background - shadedbg, + /// Text color for lyx-internal notes + notelyxinternal, + /// Background color of lyx-internal notes + notelyxinternalbg, + /// Text color for tex comments + notecomment, + /// Background color of tex comments + notecommentbg, + /// Text color for greyedout notes + notegreyedout, + /// Background color of greyedout notes + notegreyedoutbg, + /// Background color of colored notes + notecoloredbg, /// Color for the depth bars in the margin depthbar, Index: src/insets/InsetNomencl.cpp === --- src/insets/InsetNomencl.cpp (Revision 18810) +++ src/insets/InsetNomencl.cpp (Arbeitskopie) @@ -97,7 +97,7 @@ newlines += static_cast(*it).docbookGlossary(os); ++it; } else if(it->lyxCode() == Inset::NOTE_CODE && - static_cast(*it).params().type == InsetNoteParams::Note) { + static_cast(*it).params().type == InsetNoteParams::LyXInternal) { // Don't output anything nested in note insets size_t const depth = it.depth(); ++it; Index: src/insets/InsetNote.cpp === --- src/insets/InsetNote.cpp (Revision 18810) +++ src/insets/InsetNote.cpp (Arbeitskopie) @@ -50,22 +50,22 @@ NoteTranslator const init_notetranslator() { - NoteTranslator translator("Note", InsetNoteParams::Note); + NoteTranslator translator("LyXInternal", InsetNoteParams::LyXInternal); translator.addPair("Comment", InsetNoteParams::Comment); translator.addPair("Greyedout", InsetNoteParams::Greyedout); translator.addPair("Framed", InsetNoteParams::Framed); - translator.addPair("Shaded", InsetNoteParams::Shaded); + translator.addPair("Colored", InsetNoteParams::Colored); return translator; } NoteTranslatorLoc const init_notetranslator_loc() { - NoteTranslatorLoc translator(_("Note"), InsetNoteParams::Note); + NoteTranslatorLoc translator(_("LyX-internal"), InsetNoteParams::LyXInternal); translator.addPair(_("Comment"), InsetNoteParams::Comment); translator.addPair(_("Greyed out"), InsetNoteParams::Greyedout); translator.addPair(_("Framed"), InsetNoteParams::Framed); - translator.addPair(_("Shaded"), InsetNoteParams::Shaded); + translator.addPair(_("Colored"), InsetNoteParams::Colored); return translator; } @@ -89,7 +89,7 @@ InsetNoteParams::InsetNoteParams() - : type(Note) + : type(LyXInternal) {} @@ -152,7 +152,7 @@ { switch (params_.type) { case InsetNoteParams::Framed: - case InsetNoteParams::Shaded: + case InsetNoteParams::Colored: return AlignLeft; default: return Inline; @@ -186,20 +186,20 @@ Color_color c; switch (params_.type) { - case InsetNoteParams::Note: - c = Color::note; + case InsetNoteParams::LyXInternal: + c = Color::notelyxinternal; break; case InsetNoteParams::Comment: - c = Color::comment; + c = Color::notecomment; break; case InsetNoteParams::Greyedout: - c = Color::greyedout; + c = Color::notegreyedout; break; case InsetNoteParams::Framed: - c = Color::greyedout; + c = Color::notegreyedout; break; - case InsetNoteParams::Shaded: - c = Color::greyedout; + case InsetNoteParams::Colored: + c = Color::notegreyedout; break; } font.setColor(c); @@ -211,20 +211,20 @@ { Color_color c; switch (params_.type) { - case InsetNoteParams::Note: - c = Color::notebg; + case InsetNoteParams::LyXInternal: + c = Color::notelyxinternalbg; break; case InsetNoteParams::Comment: - c = Color::commentbg; + c = Color::notecommentbg; break; case InsetNoteParams::Greyedout: - c = Color::greyedoutbg; + c = Color::notegreyedoutbg; break; case InsetNoteParams::Framed: - c = Color::greyedoutbg; + c = Color::notegreyedoutbg; break; - case InsetNoteParams::Shaded: - c = Color::shadedbg; + case
Re: Shaded note => Colored Note???
On Sun, Jun 17, 2007 at 11:19:37AM +0200, Michael Gerz wrote: > Here comes a first proposal that cleans up the code. Personally, I > think that we call too many things a note. At least, we are supposed to > be consistent (internally & externally) with this patch. > > What is missing is a lyx2lyx converter that converts the two former note > types (Note & Shaded) to > >\begin_inset Note LyXInternal > > and > >\begin_inset Note Colored > > Any volunteer? Any comments? Just a comment. With this patch you are going to break compatibility with existing preferences and lyxrc.dist files. Please, don't do that. -1 -- Enrico
Re: Shaded note => Colored Note???
Also, we are supposed to focus on critical bugs now. -1 Bo
Shaded note = Colored Note???
Hi, why is a shaded note called shaded? AFAICS, a shaded note is in fact a colored note both on screen and in LaTeX output! I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. Michael
Re: Shaded note = Colored Note???
Michael Gerz wrote: Hi, why is a shaded note called shaded? AFAICS, a shaded note is in fact a colored note both on screen and in LaTeX output! I have no idea. When I added that menu entry, I stuck with the existing terminology. I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. I agree. Richard -- == Richard G Heck, Jr Professor of Philosophy Brown University http://frege.brown.edu/heck/ == Get my public key from http://sks.keyserver.penguin.de Hash: 0x1DE91F1E66FFBDEC Learn how to sign your email using Thunderbird and GnuPG at: http://dudu.dyn.2-h.org/nist/gpg-enigmail-howto
Re: Shaded note = Colored Note???
I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. I agree. Me too. Uwe
Shaded note => Colored Note???
Hi, why is a "shaded note" called "shaded"? AFAICS, a shaded note is in fact a colored note both on screen and in LaTeX output! I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. Michael
Re: Shaded note => Colored Note???
Michael Gerz wrote: Hi, why is a "shaded note" called "shaded"? AFAICS, a shaded note is in fact a colored note both on screen and in LaTeX output! I have no idea. When I added that menu entry, I stuck with the existing terminology. I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. I agree. Richard -- == Richard G Heck, Jr Professor of Philosophy Brown University http://frege.brown.edu/heck/ == Get my public key from http://sks.keyserver.penguin.de Hash: 0x1DE91F1E66FFBDEC Learn how to sign your email using Thunderbird and GnuPG at: http://dudu.dyn.2-h.org/nist/gpg-enigmail-howto
Re: Shaded note => Colored Note???
>> I suggest renaming the menu item and the underlying code. If you agree, I will prepare a patch. > I agree. Me too. Uwe