Replies: 6 comments 19 replies
-
Are you talking about : For exemple : |
Beta Was this translation helpful? Give feedback.
-
String is a ctrlr specific function (not native LUA). You'll need to do something like L is a similar function Both should do type conversion so if a is a number and b is a string, it will still concatenate, in the examples above. The only exception to this is userdata and displaying hex, for example. To display sysex in the console go here - https://ctrlr.org/forums/topic/solved-display-sysex-string-in-console/ For tables, there is a function called table.concat which should concatenate a table that can be displayed to the console. Another option is console ((string.format("Str1 %s", "Str2"))) -- Str1 Str2 |
Beta Was this translation helpful? Give feedback.
-
@unityconstruct and @Godlike-Productions. I appreciate the help but it was already stated that I'm talking about developing in the Ctrlr Source Code instead of a panel. @damiensellier. I pinpointed it to be the arguments given to the constructor. As an example for CtrlrDocumentPanel in the .h file constructing CtrlrPanelDocument: That seems to make the class accessible. However, the example given is not suitable in my case, I have to find out what I have to put there as arguments. Because I'm almost at top-level CtrlrPanel, I thought it would be: |
Beta Was this translation helpful? Give feedback.
-
The repository is up. Just click my avatar here and go to the "Ctrlr_CMake repository. I created an extra branch named "Development" that should have all the changes and probably some more unrelated "deleted comments". Keep in mind this is CMake, you need to build the build folder yourself. (It has to do with the fact that the paths being created are "absolute paths" thus user-specific, so you can do an out-of-source build). Comment out in CtlrlPropertyComponent.cpp line 313 to see the DialogWindow but as soon as you press ok, a file will be created and the crash happens upon trying to fetch the String panelBatchProjectDir. Section to comment out: I'm reading it over and over, what you wrote. Although it makes a lot of sense. I still struggle to understand why one class uses "CtrlrPanel *panel", the other one uses "CtrlrManager *owner" and the other one uses "CtrlrPanel *owner". I guess it has to do with the fact Ctrlr can open multiple panels at the same time and the Manager controls all the trees for the different panels. Thus I need to call CtrlrManager? |
Beta Was this translation helpful? Give feedback.
-
Reading your recap, I think you missed a few things that I added. No big deal. I decided to make a Gif to show how far I got with this project. As you can see, everything is in the CtrlrPropertyComponent already. You can browse to files or a folder, everything is neatly saved into the XML. No problem. Clicking on "Execute Build Script" opens a DialogWindow (the CtrlrBuildScriptDialogWindow Class that I added) That gives you options to choose your preferred build. Clicking on OK should output the Script file, which works, see the left side of the gif. The script file gets written to because it shows a dummy text that I created in the first line. But Ctrlr Crashes when I try to get the string of one of the Paths in the property panes. First of all, I have to give your "getResult()" suggestion a try. But I tried every possible combination to solve the parenting issue I mentioned. An if statement in CtrlrPropertyComponent that opens an alertwindow tells me every panel or owner that I try to call is null. Thus crashing Ctrlr when I create the script because it needs the Ids in CtrlrPanel or CtrlrManager to be accessible. I hope it's more clear now. Off to try your suggestion. |
Beta Was this translation helpful? Give feedback.
-
Some unsolicited musings:Clues for
|
Beta Was this translation helpful? Give feedback.
-
I made an extra class that opens a dialogwindow with some options. I also added some FileProperty's to set a path to files in the propertycomponent. For instance: Ids::panelBuildFolder.
It's all working including the creation of a batch file. But now I want to get the path from the ID's:: panelBuildFolder which resides in CtrlPanel.cpp to add it to the batch file. But so far no dice. The string is empty or when I change too much, results in errors.
But almost everything is done with those IDs. So, how do I use the Id in another Class? Someone care to shine some light on it?
Beta Was this translation helpful? Give feedback.
All reactions