If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Rate Thread | Display Modes |
#16
|
|||
|
|||
OK/Cancel dialog, which way round?
In article , Andy Burns
wrote: Since when was TRUE 0? https://www.gnu.org/software/coreutils/manual/html_node/true-invocation.html that's for a return value, where 0 means no error and a non-zero is an error code. But generally I agree, false is zero not just generally. it *is*. |
Ads |
#17
|
|||
|
|||
OK/Cancel dialog, which way round?
In article , Carlos E.R.
wrote: Google "what is the value of true in C". Answer: The bottom line is that, whenever a Boolean value is generated by an expression, it ... ... yields 1 if the specified relation is true and 0 if it is false. The result has type int. So, yes, the result of any Boolean-generating expression will be one for true, or zero for false. more accurately, true is non-zero (but usually 1) and false is 0. But: https://www.gnu.org/software/coreutils/manual/html_node/true-invocation.html 16.2 true: Do nothing, successfully true does nothing except return an exit status of 0, meaning success. It can be used as a place holder in shell scripts where a successful command is needed, although the shell built-in command : (colon) may do the same thing faster. In most modern shells, true is a built-in command, so when you use Œtrue¹ in a script, you¹re probably using the built-in command, not the one documented here. that's for a return value, where 0 is no error and non-zero is an error code. |
#18
|
|||
|
|||
Troll-feeding Senile IDIOTS Alert!
On Thu, 30 May 2019 23:31:19 +0200, Carlos E.R., yet another brain damaged,
troll-feeding, senile idiot, blathered: Google "what is the value of true in C". Why should he google anything when he can have endless fun baiting troll-feeding senile assholes like you? BG |
#19
|
|||
|
|||
OK/Cancel dialog, which way round?
On Thu, 30 May 2019 22:31:19 +0100, Carlos E.R. wrote:
On 30/05/2019 23.04, Commander Kinsey wrote: On Thu, 30 May 2019 21:57:14 +0100, Mayayana wrote: "Commander Kinsey" wrote | Commander Kinsey wrote: | I've never really noticed which way round these things are in Windows, | but from a Google search, it appears Windows has it backwards and MacOS | has it correct. OK on the right, this makes more sense. An affirmative | action is moreso, yes is 1, no is 0, ok should be to the right.It's | been annoying me recently in a game (Civ VI) when I automatically assume | the button on the right is "yes" and click the wrong one. | | Except usually "yes" is TRUE which is 0 not 1 in programing... | | Since when was TRUE 0? A great example of 1st world problems. Yes, 0 is false. True is 1 or -1. (A 32-bit value with all bits switched on is -1.) Google "what is the value of true in C". Answer: The bottom line is that, whenever a Boolean value is generated by an expression, it ... ... yields 1 if the specified relation is true and 0 if it is false. The result has type int. So, yes, the result of any Boolean-generating expression will be one for true, or zero for false. But: https://www.gnu.org/software/coreutils/manual/html_node/true-invocation.html 16.2 true: Do nothing, successfully true does nothing except return an exit status of 0, meaning success. It can be used as a place holder in shell scripts where a successful command is needed, although the shell built-in command : (colon) may do the same thing faster. In most modern shells, true is a built-in command, so when you use ‘true’ in a script, you’re probably using the built-in command, not the one documented here. But what we're talking about here is the attitude of the user. Most users have never heard of true being 0. However most are familiar with a car, you use the right pedal for more speed, the left pedal for less. Hence the right button should be ok or yes, and the left button cancel or no. I have a trackball that lets me put the focus on the default, so I rarely think about it, except the rare cases where I accidentally click the wrong button *because* of that feature. I never want anything to default for me. How does your computer know what you're going to want? The first button (left) is focused by default. Many programmers don't even know that, so nearly all message boxes will have the focus on the left. In that sense, the positive answer (yes or OK) is focused, which seems to accord with your prejudice. But it can be done differently if the programmer has a reason to do so. You can see it he Paste the following into Notepad, save as msg.vbs, then run it. MsgBox "first", 1 MsgBox "second", 257 Nothing should ever be focused, this means you could select it by pressing space or enter when you're in the middle of something else. Take that issue with the programmer of whatever application. Maybe even with Microsoft. Boxes have default behaviours, and the programmer chooses them. Typically "Ok" is enter, "No" or "Cancel" is Esc. And some mouse drivers (typically touchpads) have an optional function to jump the pointer automatically to the default button. Switch it on or off, your choice. That would be fine if nothing ever stole focus. But I've lost count of the number of times I'm typing an email and accidentally said "yes" to a dialog from another program. |
#20
|
|||
|
|||
OK/Cancel dialog, which way round?
On 5/30/2019 2:59 PM, nospam wrote:
In article , Carlos E.R. wrote: Google "what is the value of true in C". Answer: The bottom line is that, whenever a Boolean value is generated by an expression, it ... ... yields 1 if the specified relation is true and 0 if it is false. The result has type int. So, yes, the result of any Boolean-generating expression will be one for true, or zero for false. more accurately, true is non-zero (but usually 1) and false is 0. In other languages, I've seen the convention that false is 0 and true is -1, and other values are interpreted in such a way that all positive values are false and negative values are true....r |
#21
|
|||
|
|||
OK/Cancel dialog, which way round?
"Commander Kinsey" wrote
| What is a "control box"? | The cluster at the top right of a window (in Windows), typically with minimize, maximize/normal, and close buttons. The correlate on a Mac would be those 3 adorable gumdrops in the upper left. | I have a trackball that lets me put the focus on the default, | so I rarely think about it, except the rare cases where I | accidentally click the wrong button *because* of that feature. | | I never want anything to default for me. How does your computer know what you're going to want? | It doesn't. The trackball software makes the mouse cursor jump to the focused element. (The button that has a dotted line around it, which would be clicked if you pressed Enter.) Something is always default the focused element. Otherwise you wouldn't be able to tab around. Likewise with files in a folder. The selected item shows as selected, but if nothing is selected there's still a focused item. Ideally, the programmer who wrote the software has designed it as well as possible to predict your needs. But typically that's Yes or OK, because typically it's asking you to confirm: "Are you sure you want to delete that file?" You already did delete it, so you probably intend to answer yes. | Nothing should ever be focused, this means you could select it by pressing space or enter when you're in the middle of something else. | In most situations focus won't do that. It does with buttons in a msgbox because there's no selecting them. But with files in a folder it just sets the position where tab presses will proceed from. But it's true that could happen with a selection. You could have a selection in a folder window, then switch to Notepad. If you somehow accidentally shift the active window back to the folder when you're trying to go to the next line in Notepad then you'll end up opening the selected file or folder. That's life. Using a computer is a risky venture. Be sure you're strapped in and don't forget to take your antispasm pills before setting hand to mouse or keyboard. |
#22
|
|||
|
|||
OK/Cancel dialog, which way round?
"Commander Kinsey" wrote
That would be fine if nothing ever stole focus. But I've lost count of the number of times I'm typing an email and accidentally said "yes" to a dialog from another program. You must have some odd software. Microsoft switched that behavior years ago, so that a msgbox popped up by a window without focus goes to a flashing box on the taskbar, rather than stealing focus. Software developers can steal focus only by using hacks that are impolite and bad design. I think Imgburn might do that in some cases. I can't think of any other software that does. |
#23
|
|||
|
|||
OK/Cancel dialog, which way round?
On 31/05/2019 00.14, Commander Kinsey wrote:
On Thu, 30 May 2019 22:31:19 +0100, Carlos E.R. wrote: On 30/05/2019 23.04, Commander Kinsey wrote: On Thu, 30 May 2019 21:57:14 +0100, Mayayana wrote: "Commander Kinsey" wrote | Commander Kinsey wrote: | I've never really noticed which way round these things are in Windows, | but from a Google search, it appears Windows has it backwards and MacOS | has it correct.Â* OK on the right, this makes more sense.Â* An affirmative | action is moreso, yes is 1, no is 0, ok should be to the right.It's | been annoying me recently in a game (Civ VI) when I automatically assume | the button on the right is "yes" and click the wrong one. | | Except usually "yes" is TRUE which is 0 not 1 in programing... | | Since when was TRUE 0? Â*A great example of 1st world problems. Â*Yes, 0 is false. True is 1 or -1. (A 32-bit value with all bits switched on is -1.) Google "what is the value of true in C". Answer: The bottom line is that, whenever a Boolean value is generated by an expression, it ... ... yields 1 if the specified relation is true and 0 if it is false. The result has type int. So, yes, the result of any Boolean-generating expression will be one for true, or zero for false. But: https://www.gnu.org/software/coreutils/manual/html_node/true-invocation.html 16.2 true: Do nothing, successfully true does nothing except return an exit status of 0, meaning success. It can be used as a place holder in shell scripts where a successful command is needed, although the shell built-in command : (colon) may do the same thing faster. In most modern shells, true is a built-in command, so when you use ‘true’ in a script, you’re probably using the built-in command, not the one documented here. But what we're talking about here is the attitude of the user.Â* Most users have never heard of true being 0.Â* However most are familiar with a car, you use the right pedal for more speed, the left pedal for less.Â* Hence the right button should be ok or yes, and the left button cancel or no. Middle pedal here is less. But we programmers never thought in those terms. Try with politics :-p And some mouse drivers (typically touchpads) have an optional function to jump the pointer automatically to the default button. Switch it on or off, your choice. That would be fine if nothing ever stole focus.Â*Â* But I've lost count of the number of times I'm typing an email and accidentally said "yes" to a dialog from another program. Yep. So I don't enable that automatism. -- Cheers, Carlos. |
#24
|
|||
|
|||
OK/Cancel dialog, which way round?
In message Commander Kinsey wrote:
I've never really noticed which way round these things are in Windows, but from a Google search, it appears Windows has it backwards and MacOS has it correct. OK on the right, this makes more sense. An affirmative action is moreso, yes is 1, no is 0, ok should be to the right. It's been annoying me recently in a game (Civ VI) when I automatically assume the button on the right is "yes" and click the wrong one. One of the more minor things I dislike about Windows, but a constant source of low-grade annoyance. It has even migrated to some other terrible UI decisions, like POS terminals that put cancel on the bottom right. -- I must admit, you brought Religion into my life. I never believed in Hell until I met you. |
#25
|
|||
|
|||
OK/Cancel dialog, which way round?
On 31/05/19 06:32, Jonathan N. Little wrote:
Commander Kinsey wrote: I've never really noticed which way round these things are in Windows, but from a Google search, it appears Windows has it backwards and MacOS has it correct. OK on the right, this makes more sense. An affirmative action is moreso, yes is 1, no is 0, ok should be to the right. It's been annoying me recently in a game (Civ VI) when I automatically assume the button on the right is "yes" and click the wrong one. Except usually "yes" is TRUE which is 0 not 1 in programing... Only in C programming, not in the better programming languages. -- Peter Moylan http://www.pmoylan.org Newcastle, NSW, Australia |
#26
|
|||
|
|||
OK/Cancel dialog, which way round?
In article , Peter Moylan
wrote: Except usually "yes" is TRUE which is 0 not 1 in programing... Only in C programming, not in the better programming languages. nope. historically, false is 0 and true is non-zero, but in c99, bool is 0 or 1 (although testing for 1 is still a bad idea). http://pubs.opengroup.org/onlinepubs...stdbool.h.html https://clang.llvm.org/doxygen/stdbool_8h_source.html |
#27
|
|||
|
|||
Troll-feeding Senile IDIOT Alert!
On Thu, 30 May 2019 20:56:31 -0400, Mayayana, another obviously brain dead,
troll-feeding senile idiot, blathered again: You must have some odd software. Nope, it's his head that is odd ...VERY odd! But you are obviously too senile to notice it, troll-feeding idiot! BG |
#28
|
|||
|
|||
Troll-feeding Senile IDIOTS Alert!
On Fri, 31 May 2019 03:48:52 +0200, Carlos E.R., another mentally
challenged, troll-feeding, senile idiot, blathered again: the number of times I'm typing an email and accidentally said "yes" to a dialog from another program. Yep. So I don't enable that automatism. What has all this demented **** got to do with a group like aue, you driveling IDIOTS? |
#29
|
|||
|
|||
Troll-feeding Senile IDIOTS Alert!
On Thu, 30 May 2019 20:51:20 -0400, Mayayana, another obviously brain dead,
troll-feeding senile idiot, blathered again: | I never want anything to default for me. How does your computer know what you're going to want? | It doesn't. LOL Another senile idiot who GLADLY takes the dumbest baits from one of the dumbest trolls that ever infested these groups! |
#30
|
|||
|
|||
Troll-feeding Senile IDIOTS Alert!
On Fri, 31 May 2019 02:05:45 -0000 (UTC), Lewis, another mentally
challenged, troll-feeding, senile idiot, driveled: One of the more minor things I dislike about Windows, but a constant source of low-grade annoyance. Good for you that you found a retarded troll to talk to about your dislike, eh, senile Lewis? VBG |
Thread Tools | |
Display Modes | Rate This Thread |
|
|