RadioButtonList Region

RadioButtonList Region - adds RadioButtonList controls to SMath Studio and SMath Viewer - Messages

#1 Posted: 3/13/2014 7:40:44 PM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

SMath Studio compatibility SMath Viewer compatibility mono compatibility

extension page Sources MIT license


- Allowed inputs: mouse click, mouse wheel, + and - keys;
- Settings: double-click over the region.
- Input: any vector/matrix/system with two or more rows.
- Output: place a variable in the region placeholder.
- Size driven by the values (manual resize not allowed).
- Adds the same control in SMath Viewer (using the same layout).

Look in the attachment for more details and features.

PLEASE REPORT HERE ANY ISSUE

Show Spoiler





Control Regions: CheckBoxList | ComboBoxList | ConditionallyFormattedLabelNumericUpDown | PathPicker | RadioButtonList | Slider
features & examples.sm (18 KiB) downloaded 394 time(s).
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
5 users liked this post
Martin Kraska 3/14/2014 1:53:00 PM, Вячеслав Мезенцев 3/13/2014 10:20:00 PM, sergio 3/14/2014 5:04:00 AM, ioan92 3/13/2014 9:21:00 PM, IVR 3/14/2014 10:55:00 AM
#2 Posted: 3/14/2014 5:14:26 AM
sergio

sergio

115 likes in 329 posts.

Group: User

Thanks Davide for the great job

I don't mind using the two-column matrix; In some situations is a nice shortcut for define the variable in output.
Perhaps it would be useful to differentiate the instrument through an option.

sergio
#3 Posted: 3/14/2014 8:00:18 AM
zorrykid

zorrykid

5 likes in 18 posts.

Group: User

Thanks a lot and best regards

Franco
#4 Posted: 3/14/2014 8:29:48 AM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

Wrote

Thanks Davide for this exquisite gift,

It really fills a missing tool place !


You're welcome :d

Wrote

I noticed that when a matrix is taken as input source, the output is no more the selected line number,
but it corresponds to the value for the selected line in the second column of this matrix.
From my viewpoint, it would be preferable to have as output always the selected line number, in order to be able to recover the whole line of the matrix, especially when the matrix has more then 2 columns (!?).


Ok, I can easily suppress this feature, I've just reproduced the combobox behavior


No feedbacks about the new symbolic features shown in the first attachment?


Best regards,

Davide
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 users liked this post
ioan92 3/14/2014 9:33:00 AM
#5 Posted: 3/14/2014 11:41:44 AM
sergio

sergio

115 likes in 329 posts.

Group: User

In the previous post I had not yet used the example.
now, more than before, I can confirm that two-column matrix is fantastic for me

sergio
#6 Posted: 3/14/2014 1:53:00 PM
Martin Kraska

Martin Kraska

1222 likes in 2150 posts.

Group: Moderator

Wrote

No feedbacks about the new symbolic features shown in the first attachment?


Great to see that you have access to the math region formatting capabilities within custom regions.

Given the depth of your insight into the machinery, I see potential for great things to become true:
- plot regions with placeholders for axis limits and arbitrary expressions for annotation
- Text region with math insets and rtf formatting capabilities
- seamlessly integrated matrix editor
- Tabular input feature (like in Mathcad)
- Tabular display using math-region-consistent formatting
- advanced result formatting (numbers of significant digits, polar form of complex numbers)
- special markup for nonscalar variables (boldface)
- Fulltext search (in the open sheet and in directory trees)
But don't be too fast, even now it is hard to keep up documenting... ;-)






Martin Kraska Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
1 users liked this post
Davide Carpi 3/14/2014 3:55:00 PM
#7 Posted: 3/14/2014 4:02:24 PM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

I've updated the plugin, now the output is always the item number; thinking a little while about it, my opinion is that the default output should be this... I'll think if and how to introduce a choice to the output (the ordinal number rather than the whole row or an element in a column...)


best regards,

Davide
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 users liked this post
ioan92 3/14/2014 4:14:00 PM
#8 Posted: 3/14/2014 5:04:25 PM
Martin Kraska

Martin Kraska

1222 likes in 2150 posts.

Group: Moderator

I do not really understand the problem with the return values taken from the second column of a matrix. If the line number is the desired output, just fill the second column with appropriate numbers or access the complete line via findrows().
rblr.PNG
Martin Kraska Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
1 users liked this post
Davide Carpi 3/14/2014 7:10:00 PM
#9 Posted: 3/14/2014 8:15:17 PM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

Thank you Martin, this is true

From my point of view there are enough tools to make any solution usable, but there are "better" and "less better" ways.

Talking about general cases, with the first approach (emulation of combobox behavior) if you want the index from a matrix for post-processing purposes (get the whole row, get the n-th element of that row, or get something else not directly related), you need a pre-processing by assigning the first column to a new variable or some post-processing operation (like that made by you with findrows; here you assume that the second column contains only different values, but you may encounter some problems when the second column contains several equal values).

In the other hand making the option index as output always available there's no needs to make pre-processing operations and any post-processing operation could start from an unique identifier without issues; moreover, as I've written in my previous post, I think that it's possible to move the most common desired outputs directly inside the region dialog (if my explaination was not too much confused, it should emerge that these options are for a very specific context, namely that in which the region drives only the parameters of the input matrix; if the region drives also other things, like corresponding parameters in other matrices/tables, the index is again the most important thing). As "secondary" matter, this is a more linear approach: any allowed input returns as default output the row index of the selected item).

However the plugin is a beta and I'm opened to any suggestion


Best regards,

Davide
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
2 users liked this post
ioan92 3/15/2014 2:40:00 AM, Martin Kraska 3/15/2014 2:55:00 AM
#10 Posted: 3/15/2014 2:53:50 AM
Martin Kraska

Martin Kraska

1222 likes in 2150 posts.

Group: Moderator

Yes, perhaps it is a good idea to have a choice in the settings (radio button?) of what the output should be (row index, column number, where to get the value, complete row...).

Now something different. The discussion on parametrization of smath sheets "from below" caused me to have a closer look on what Andrey calles "absolute definitions", see http://en.smath.info/forum/yaf_postst1348_Absolute-definitions.aspx

If an absolute variable is used as output, then the radio button region fails to trigger re-calculation, even if it looses mouse focus. In contrast to that, normal variables react imediately to button actions.

In order to get the sheet consistent, manual recalculation is required.
Parametrierung.sm (4 KiB) downloaded 128 time(s).
Martin Kraska Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
2 users liked this post
sergio 3/15/2014 4:39:00 AM, Davide Carpi 3/16/2014 9:12:00 AM
#11 Posted: 3/15/2014 11:44:07 AM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

Wrote

Now something different. The discussion on parametrization of smath sheets "from below" caused me to have a closer look on what Andrey calles "absolute definitions", see http://en.smath.info/forum/yaf_postst1348_Absolute-definitions.aspx

If an absolute variable is used as output, then the radio button region fails to trigger re-calculation, even if it looses mouse focus. In contrast to that, normal variables react imediately to button actions.

In order to get the sheet consistent, manual recalculation is required.


I think that absolute definitions could be useful also in the modeller region
Seems a SMath bug or "unimplemented feature"... if you use a classic variable as output (a) and then you define the absolute variable using the output (∼a:a), the result is the same...

Wrote

I change, by the program, the Input Data source for the Button List and, for every input change, the setting "split every" is reset to the default "all the list"(!?).


The layout and the number of consecutive elements are unset when you change the input size (number of rows)
As for the layout, there are no problems... The "split every" value is a little bit more complicated to drive...

Wrote

Do you imagine a font control for the list. As it is, it seems using an embedded unique font, without any possibility of changing ?


Actually there are some small issues in Math regions when you change the fonts (you can see something exporting the example worksheet in SMath Viewer), but is it in my plans...


best regards,

Davide
2014-03-15 16_43_01-SMath Studio Desktop - [features & examples.sm_].png
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 users liked this post
ioan92 3/15/2014 12:43:00 PM
#12 Posted: 3/17/2014 5:36:24 PM
Andrey Ivashov

Andrey Ivashov

2270 likes in 3734 posts.

Group: Super Administrator

I think plug-in should be recompiled. Sorry for this, but I have to do some critical changes in Custom Regions mechanizm in order to provide new features in future.
2 users liked this post
ioan92 3/17/2014 5:40:00 PM, Davide Carpi 3/17/2014 7:22:00 PM
#13 Posted: 3/17/2014 7:24:02 PM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

UPDATED

(SMath Studio 0.97.5189)

- code updated to fit the new APIs features;

Wrote

I think plug-in should be recompiled. Sorry for this, but I have to do some critical changes in Custom Regions mechanizm in order to provide new features in future.


Don't worry Andrey, any improvement is highly welcome! (and the plugin version in the EM is very useful to avoid confusion)


Best regards,

Davide
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#14 Posted: 3/18/2014 7:13:52 AM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

UPDATED

(SMath Studio 0.97.5189)

- Layout & split settings propagated when data size changes;
- fixed clicks on "white cells";
- fixed clicks on empty regions.
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
2 users liked this post
ioan92 3/18/2014 7:24:00 AM, Andrey Ivashov 3/18/2014 4:10:00 PM
#15 Posted: 3/22/2014 1:33:50 PM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

UPDATED

(SMath Studio 0.97.5189)

- SMath Viewer: uses the region description (if exist and is shown).
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 users liked this post
ioan92 3/22/2014 2:07:00 PM
#16 Posted: 4/15/2014 7:41:15 AM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

UPDATED
(SMath Studio 0.97.5189)

  • BTS SS-103 features (extended)
    - select input column
    - select output type (index, element from a column, whole row)
    - select text Font
    - select text Color (from SMath toolbar)
  • RBs now uses MathRegions for any element shown (except strings at the first nesting level)
  • Added number's formatting (at the first nesting level)



NOTE: The plugin should be back-compatible with the previous version; this compatibility will be extended as long as possible but I suggest to update any document containing this plugin to avoid problems in the future.
2014-04-15 13_45_45-Greenshot capture form.png
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#17 Posted: 4/15/2014 11:40:35 AM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

Wrote

Grazzie mille !


de rien! :d


BTW this version of the plugin should be the backbone of the ComboBoxList plugin (SS-102) so any feedback about bugs or lacks is important.


Best regards,

Davide
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 users liked this post
ioan92 4/16/2014 2:39:00 PM
#18 Posted: 4/18/2014 1:26:24 PM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

UPDATED
(SMath Studio 0.97.5189)

- fixed number's settings when dialog exit condition is not "OK";
- minor changes;
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#19 Posted: 4/19/2014 3:40:31 AM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

Hi Ioan, happy Easter to you

With my files I can't reproduce this issue, can you attach here or send me a file with this issue?


Best regards,

Davide

---

edit: this is a back-compatibility issue. Anyone that experiment this problem can replace with a text editor the XML code:

      <ul>
        <li>a string</li>
        <li>a string</li>
        <li>a string</li>
        <li>a string</li>
      </ul>

with:

      <ul>
        <li>#</li>
      </ul>

then the file can be opened and saved again, without losses.
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 users liked this post
ioan92 4/19/2014 1:36:00 PM
#20 Posted: 4/8/2015 4:53:26 AM
Davide Carpi

Davide Carpi

1417 likes in 2873 posts.

Group: Moderator

PLUGIN UPDATED

- Plugin updated to respect changes in SS Core;
- Evaluation on end of multiple MouseWheel calls or +/- keys pressed restored;
- +/- fixed to work with any localization;
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
1 users liked this post
ioan92 4/9/2015 2:01:00 AM
  • New Posts New Posts
  • No New Posts No New Posts