Subject: mailing-list for TeXmacs Users
List archive
From : Sam Liddicott <address@hidden>- To: Alexandre Dezotti <address@hidden>
- Cc: "address@hidden" <address@hidden>
- Subject: Re:[TeXmacs]
- Date: Wed, 29 Apr 2015 13:53:27 +0100
Thanks to Miguel with text-at-valign etc, I attach a much better comsquare
if a size is not given it defaults to 7fs which I think is the smallest you can reasonably getOn Tue, Apr 28, 2015 at 2:15 PM, Alexandre Dezotti <address@hidden> wrote:
@Nicola Now, I remember you signalling of that problem.Thank you for your answers.
@Sam I will take a closer look at your macro to see how it works so that I can elaborate on this.2015-04-28 12:22 GMT+02:00 Sam Liddicott <address@hidden>:I should probably be measuring the width of a each text box for better placement, especially of the smaller letters on the sidesI'm not happy with the accuracy of placement.the final argument is the size of the square in fs units (multiple of font size).Here is my best approach so far.<\comsquare|A|B|C|D|e|f|g|h|20fs>
text-at seems to be only top-left based and I want centre based.
Adjustments based on a proportion of fs isn't accurate enough.
but I don't have the spare brain cycles to do that right now.Also I'm not sure why the final argument size isn't showing up in the toolbar as most inaccessible arguments should.SamOn Sun, Apr 26, 2015 at 10:27 PM, Miguel de Benito Delgado <address@hidden> wrote:Hi,I see three choices:1. Use tables: DON'T! It'll look ugly.2. Use one of the latex packages for commutative diagrams like tikz or xymatrix via a TeXmacs plugin. DON'T! We want to avoid LaTeX, right? Also, I doubt those plugins have been maintained recently.3. Use TeXmacs graphics.Well, my suggestion is clear ;)Insert->Image->Draw image will get you started. Remember that you can resize the canvas using A-Left, A-Down, etc. Use shift to go faster. Use the grid to snap your text, math and arrows, then hide it.Once you have one diagram made, you can copy and paste the whole drawing anywhere in your document, and you can easily create a macro out of it, again copying and pasting.If you want to go deeper, you can create a so-called "graphical macro". This would let you create and insert components for your commutative diagrams using the interface for the drawing tool and it's easier than it seems. To see what I mean, add the style package Experimental->graphical-macros to your document, then Insert a drawing and change the active tool by clicking on "Point" in the focus bar. You'll see new stuff there.Hth,--
Miguel de Benito.On Sun, Apr 26, 2015 at 3:22 PM, Alexandre Dezotti <address@hidden> wrote:HI all,I am wondering if there is a recommended way to do commutative diagrams with Texmacs. I just need the simple commutative square such as: https://upload.wikimedia.org/wikipedia/commons/9/91/Commutative_square.svg ?I get a "Internal Server Error".Best,AD.
<TeXmacs|1.99.2> <style|<tuple|generic|british|graphical-macros>> <\body> <assign|boxy-info|<macro|tree|boxy|cmd|<with|l|<look-up|<arg|boxy>|0>|r|<look-up|<arg|boxy>|1>|t|<look-up|<arg|boxy>|2>|b|<look-up|<arg|boxy>|3>|w|<look-up|<arg|boxy>|4>|h|<look-up|<arg|boxy>|5>|<arg|cmd>>>> <assign|with-box-info|<macro|tree|x|<boxy-info|<arg|tree>|<box-info|<arg|tree>|lrtbwh>|<arg|x>-<arg|cmd>>>> \; <assign|comsquare|<macro|a|b|c|d|e|f|g|h|size|<with|gr-mode|<tuple|edit|text-at>|gr-frame|<tuple|scale|1fs|<tuple|0.5gw|0.5gh>>|gr-geometry|<tuple|geometry|<if|<equal|<arg|size>|>|7fs|<arg|size>>|<if|<equal|<arg|size>|>|7fs|<arg|size>>|center>|gr-arrow-end|\<gtr\>|text-at-halign|center|text-at-valign|center|<graphics||<text-at|<math|<arg|a>>|<point|<plus|0gw|1fs>|<minus|0.5gh|1fs>>>|<text-at|<math|<arg|b>>|<point|<minus|1gw|1fs>|<minus|0.5gh|1fs>>>||<text-at|<math|<arg|c>>|<point|<plus|0gw|1fs>|<minus|-0.5gh|-1fs>>>|<text-at|<math|<arg|d>>|<point|<minus|1gw|1fs>|<minus|-0.5gh|-1fs>>>|<with|arrow-end|\<gtr\>|<line|<point|<plus|0gw|2fs>|<minus|0.5gh|1fs>>|<point|<minus|1gw|1.8fs>|<minus|0.5gh|1fs>>>>|<with|arrow-end|\<gtr\>|<line|<point|<minus|1gw|1fs>|<minus|0.5gh|2fs>>|<point|<minus|1gw|1fs>|<minus|-0.5gh|-2fs>>>>|<with|arrow-end|\<gtr\>|<line|<point|<plus|0gw|1fs>|<minus|0.5gh|2fs>>|<point|<plus|0gw|1fs>|<minus|-0.5gh|-2fs>>>>|<with|arrow-end|\<gtr\>|<line|<point|<plus|0gw|2fs>|<minus|-0.5gh|-1fs>>|<point|<minus|1gw|2fs>|<minus|-0.5gh|-1fs>>>>|<text-at|<math|<arg|e>>|<point|0.5gw|<minus|0.5gh|0.5fs>>>|<text-at|<math|<arg|f>>|<point|<plus|1gw|-0.5fs>|0gh>>|<text-at|<math|<arg|g>>|<point|0.5gw|<minus|-0.5gh|-0.5fs>>>|<text-at|<math|<arg|h>>|<point|<plus|0gw|0.50fs>|0gh>>>>>> <comsquare|A|B|C|D|e|f|g|h|7fs><comsquare|A|B|C|D|e|f|g|h|10fs><comsquare|A|B|C|D|e|f|g|h|15fs> <comsquare|A|D|A|A|f|a|D|a|> \; </body> <\initial> <\collection> <associate|preamble|false> </collection> </initial>
- [TeXmacs], Alexandre Dezotti, 04/26/2015
- Re:[TeXmacs], Nicola Mingotti, 04/26/2015
- Re:[TeXmacs], Miguel de Benito Delgado, 04/26/2015
- Re:[TeXmacs], Sam Liddicott, 04/28/2015
- Re:[TeXmacs], Alexandre Dezotti, 04/28/2015
- Re:[TeXmacs], Miguel de Benito Delgado, 04/28/2015
- Re:[TeXmacs], Nicola Mingotti, 04/28/2015
- Re:[TeXmacs], Sam Liddicott, 04/29/2015
- Re:[TeXmacs], Miguel de Benito Delgado, 04/28/2015
- Re:[TeXmacs], Miguel de Benito Delgado, 04/28/2015
- Re:[TeXmacs], Alexandre Dezotti, 04/28/2015
- Re:[TeXmacs], Sam Liddicott, 04/28/2015
Archive powered by MHonArc 2.6.19.