Imgui: Slider available when checkbox checked

Created on 1 Mar 2018  路  7Comments  路  Source: ocornut/imgui

Hello, so I have a question. Is it possible to make that sliders to be available only when a checkbox is checked?
slider

Like, FOV View and FOV Model View to be visible/available only when FOV Changer checkbox is checked?

Most helpful comment

Edited with details and for clarity
@aylaylay It's not my business what they use it for, it's my business to decide if want to spend time helping people.

The amount of support requests are already overwhelming, I'm doing this by myself, and there is a huge overlap between cheaters and: ill-defined time-wasting requests from entitled people who have no interest in programming and asking me to solve their homework while making it as hard as possible to me to mind-read them and guess what their code looks like.

Add to the equation that their project are unethical, it's an easy line to draw really: I can't give out my time away helping them.

All 7 comments

Yes, you can use an if statement.

Can you give me an example, please?

Please refer to C/C++ books or tutorials about how to use if statements, here isn鈥檛 the place sorry.

Apologies to myself, I didn't immediately realize this was another case of CS GO cheating.
Sorry but #1586

How is it any of your business what he's using it for?

Edited with details and for clarity
@aylaylay It's not my business what they use it for, it's my business to decide if want to spend time helping people.

The amount of support requests are already overwhelming, I'm doing this by myself, and there is a huge overlap between cheaters and: ill-defined time-wasting requests from entitled people who have no interest in programming and asking me to solve their homework while making it as hard as possible to me to mind-read them and guess what their code looks like.

Add to the equation that their project are unethical, it's an easy line to draw really: I can't give out my time away helping them.

@Haterul if u can spend 1 sec on reading the demo n u'll know:

static bool isChecked = false;
ImGui::Checkbox("FOV Changer", &isChecked);
if (isChecked) {
  ImGui::SliderInt // pass your arguments
}
Was this page helpful?
0 / 5 - 0 ratings

Related issues

bogdaNNNN1 picture bogdaNNNN1  路  3Comments

noche-x picture noche-x  路  3Comments

NPatch picture NPatch  路  3Comments

spaderthomas picture spaderthomas  路  3Comments

bizehao picture bizehao  路  3Comments