last day (15 days later) » 

10:54 PM
6
A: list of and add to toc mdframed objects

Gonzalo MedinaOne possibility: \documentclass{article} \usepackage[utf8]{inputenc} \usepackage[T1,T2A]{fontenc} \usepackage[english,russian]{babel} \usepackage[a5paper]{geometry} \usepackage{amsthm,thmtools} \usepackage[framemethod=tikz]{mdframed} \usepackage{amsmath,amssymb} \usetikzlibrary{shadows.blur} \us...

 
excellent..tanks..I dont know too much latex programming internals . I used example from link above and wrapped mdframed env with command + tocloft..but your approach is much better
this transformation formulaes getting popular :) ..just kidding :) p.s. and of course i just need renewcommand for chapter/section/ numbering during sectioning i guess
I added counter to code ' {\addcontentsline{mdf}{figure}{\theexercise~ #2}' and counters go strange in listof..The first counter starts from 0..if i step counter on the top, tnan environmet conter is +1 extra
fixed it with this one: \newenvironment{mythm}[2][]
{\addtocounter{exercise}{+1} \addcontentsline{mdf}{figure}{\theexercise #2}\addtocounter{exercise}{-1} \begin{mdframed}[style=exercisestyle,#1,title=#2]}
{\end{mdframed}} before entering in environmet counter is not increased yet and this -1 data is written to toc
and better is \theexercise{} just for extra space
 
@LevanShoshiashvili all those manipulations with the counter are not necessary; please see my updated answer, and specially the final remarks.
 
Thanks again :)
hmm strange behavior..it was not before...place 3,4 of mythm blocks (just copy/paste) and you will se very strange behavior of 3rd object when it is splited across pages.
 
@LevanShoshiashvili if you are referring to the clubsuit decoration when the frame splits, that part of your original code: you have {\node[pointstyle, left,xshift=1cm] {$\clubsuit$};} inside firstextra. If you don't want that, then don't use it. To prevent a page break in some undesired location, you can use the option nobreak=true.
 
Ok..but during page brake clubsuit is changed :) and title also gets lost in initial code i stared with clubsuit was just disappearing and other decorations were kept..its ok this behavior can be avoided..this is just user code not a class/style package..thanks again
changed 'fig=suit' to bydefault fig is empty works fine.So i can don't pass fig if frame splits
but in this last code title also gets lost..even i remove default suit thing
 
10:54 PM
@LevanShoshiashvili it's impossible to know what you're talking about without seeing the actual code you are using. Please edit your question and add, as an edit, the code you are currently using and some text illustrating the problem. (Please don't overwrite the already existing code)
 
updated..I did not know if this was allowed. I got warning once , when i reposted question as answer to my own question :)
 
@LevanShoshiashvili Of course, it's allowed, but without deleting the previous code; otherwise the initial question and answer makes no sense! Please reedit, to include the old code and add the new code afterwards, with the new requirements.
 
Updated...with original code
found solution. I changed first extra like this in your code and I dont know how good is this change , but it works fine: <code>firstextra={%
\node[titregris,xshift=1cm] at (P-|O) %
{~\mdf@frametitlefont{მაგალითი~\textnumero\theexercise}~\mdf@@title};
\ifdefempty{\mdf@@exercisepoints }%
{}%
{\node[pointstyle,left,xshift=-1cm] at (P)%
{~\mdf@frametitlefont{\mdf@@exercisepoints points}~};},%
%{\node[pointstyle, left,xshift=1cm] {$\clubsuit$};}
}</code>
 
@LevanShoshiashvili I just wrote that in my updated answer :-) Also, notice the use of \displaybreak in the third frame; long equations at the end of a page are problematic, so \displaybreak is needed.
@LevanShoshiashvili And sorry to insist on this, but please consider accepting answers to your questions.
 
now one more comes...for not dublicating code for different environmets 'MyExample1' and MySolutionAnother can envoronment name be passed to mdframe somehow? and i dont like global counter can it be created behind user?
 
10:54 PM
@LevanShoshiashvili I don't fully understand your questions. Do you need another environment with similar settings but with a different name? Can we continue this discussion in chat?
@LevanShoshiashvili Hi!
@LevanShoshiashvili I have to leave now, but in some hours I'll be back. You can leave any message here, if you want.
 
11:21 PM
hi
Let Say I have this objects in book:
1. example (question with solution just after question)
2. homework (inline question for homework). For this 2 things this nice frames are very good and imperssive..i'l have frames with different colors/counters etc..so i need to copy/paste. For Problems/Solution (when there are many..)staff other packages might be used thay dont need framed.It woud be wasting of space.
Another possibility just to glue amsmath/ntheorem with this design we ar discussing right now..i know examples from mdframed package but this fancytitleboxes with full controll,what we ar discussing last days are very nice to have 'out of box'
most simpler for user let say i got new theorem from somepackage tex.stackexchange.com/questions/53978/custom-theorem-numbering now if we have command '\mdfsetup{%}'
most simpler for user let say i got new theorem from somepackage tex.stackexchange.com/questions/53978/custom-theorem-numbering now if we have command '\mdfsetup{%}'{gluetheorem=MyTestTheoremCreatedAbove,...someother..options} and/or \mdfdefinestyle{fanymdframewearediscussing}{glue=MyTestTheoremCreatedAbove} and mdframed@glue will scan theorem and pass counter and name to fancyboxtheoremstyle ...
.just wondeing..i know its alot of work..i myself do C++ and know when somenone says 'can you add this small feature?' it menas about 1 month work :)
Ok i go sleep now here is about 3:40AM :)
and thanks for helping
 

last day (15 days later) »