Closed Synth9283 closed 4 years ago
This report is not helpful?
Which os are you on?
Please provide a minimal example showing the error.
The link you provided is working as expected.
OS: Arch Linux Example:
import nigui
app.init()
var window = newWindow()
var container = newLayoutContainer(Layout_Vertical)
window.add(container)
# Adds a button
var loadButton = newButton("Load")
container.add(loadButton)
# Add a Progress Bar control:
var progressBar = newProgressBar()
container.add(progressBar)
# When load button is clicked
loadButton.onClick = proc(event: ClickEvent) =
for i in 0..100:
progressBar.value += float(0.01)
window.show()
app.run()
I wish to increment and progressBar as shown from above. However, I am not able to due to an error response of progressBar.value
being immutable
value
is a getter procedure, not a field.
progressBar.value = progressBar.value + 0.01
It works! Thank you very much! I am very sorry about this
Greetings, I have lately started using the NiGui library. However, I have recently encountered a problem where I am not able to change the
progressbar.value
as displayed here on line 26 inside a for loop with an onButtonClick event