|
Absolutely. Send it ASAP!!
Do you happen to have the HUGE wall chart of the MFC class hierarchy?
Remember those?
|
|
|
|
|
I remember it well, but I don't think it survived intact. I had it on a wall at one time, but that was long ago. I tried for years to master C++ and MFC, and finally gave up. Neither made a lick of sense, just a giant step backward from the goal of readable, maintainable code.
Will Rogers never met me.
|
|
|
|
|
raddevus wrote:
But for hours I could not figure out why the button wouldn't render itself properly -- the text (content) on the button will not display. Why didn't you ask a question in the forums here? I could have offered some pointers. Are you using VS2015? Why didn't you use the Live Property and Live Visual Tree to help resolve?
This space for rent
|
|
|
|
|
Pete O'Hanlon wrote: Why didn't you ask a question in the forums here?
I got caught up in my rant.
Pete O'Hanlon wrote: Are you using VS2015?
Yes
Pete O'Hanlon wrote: Why didn't you use the Live Property and Live Visual Tree to help resolve?
I only knew about these from sideways references.
You are most kind to point this all out. Next time -- and there will be a next time -- I will ask here.
Also, I finally found the answer by breaking everything and putting it all back together.
The Content="asdfasdf" would not display on the button because it was way off the "edge" of the button.
As soone as I added padding="0" it snapped to the middle of the button.
|
|
|
|
|
I shall be glad to offer help, if I can. And yes, padding can be a bitch.
This space for rent
|
|
|
|
|
Pete O'Hanlon wrote: And yes, padding can be a bitch.
Truer words were never spoken.
It was a very small button and I had HorizontalContentAlignment="Left" and I ignorantly _assumed_ that the char would display. And then I just ran down a road based upon foolish ignorance and expectation.
I was stuck in a locus of attention and couldn't break out.
Finally, I remembered, "Hey, let's break this thing really bad!" Then I beat it.
|
|
|
|
|
Plus, people actually use android apps.
"universal" apps are only used if there isn't an alternative.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
Mark_Wallace wrote: Plus, people actually use android apps.
"universal" apps are only used if there isn't an alternative.
Two very good points. Agreed.
|
|
|
|
|
And falls into a coma.
Six-months later he wakes up in a car.
The woman is driving, and barking.
"Why are you barking?," the man says.
"So your son can stay asleep," she says.
"Shouldn't you be singing a ... lullaby ?," he says.
"Wait 'till you see the mutt," she says.
«There is a spectrum, from "clearly desirable behaviour," to "possibly dodgy behavior that still makes some sense," to "clearly undesirable behavior." We try to make the latter into warnings or, better, errors. But stuff that is in the middle category you don’t want to restrict unless there is a clear way to work around it.» Eric Lippert, May 14, 2008
|
|
|
|
|
And what are you smoking?
Not that I want any. I would prefer to keep my sanity.
What do you get when you cross a joke with a rhetorical question?
The metaphorical solid rear-end expulsions have impacted the metaphorical motorized bladed rotating air movement mechanism.
Do questions with multiple question marks annoy you???
|
|
|
|
|
Brisingr Aerowing wrote: And what are you smoking? Bill no smoke, no drug, all crazy natural no chemical additives.
«There is a spectrum, from "clearly desirable behaviour," to "possibly dodgy behavior that still makes some sense," to "clearly undesirable behavior." We try to make the latter into warnings or, better, errors. But stuff that is in the middle category you don’t want to restrict unless there is a clear way to work around it.» Eric Lippert, May 14, 2008
|
|
|
|
|
...and falls into a coma.
Six months later, she wakes to find she's no longer pregnant. Frantic, she asks the doctor what happened to her baby.
"You had twins! A boy and a girl, they are both fine - your brother named them."
"Oh no - not my stupid brother! What did he call them?" She asked, fearing the worst.
"Denise for the girl...."
She is hugely relieved! "That's OK!" she exclaims. "I like Denise, that's a good name!"
"...and the boy is Denephew."
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
|
|
|
|
|
he is a shelfish man
___@sHubHa
|
|
|
|
|
|
Just trying to create a Dictionary-ish class in JavaScript.
Wanted to make it as much as the C# one as possible.
The C# one has a constructor with an IEqualityComparer .
I thought I knew how it worked (I've written a few), but apparently I didn't.
Not enough to implement it without spending about an hour or two figuring out how it works anyway.
Why DOES an IEqualityComparer have a GetHashCode AND an Equals function anyway? Hash collisions you say? FFFFFFFUUUUUUU...
Now to work around the fact that JavaScript is a messed up "language" and dictionaries can't be implemented because it doesn't have a proper hash function
It's good to have a hobby
P.S. Ever wanted to mess up your Dictionary? Write an EqualityComparer where Equals always returns false. You haven't really lived until you've tried it
|
|
|
|
|
"When you realize you don't know what you thought you knew" ... that is when you, very temporarily, most often without suspecting it, have wisdom.
If (may the gods spare me) I had to emulate a .NET Dictionary in EcmaScript, I would be tempted just to make sure the 'Add function failed if the candidate Key was a duplicate, but I like the fact you are going for the full-monty, hash, and all.
cheers, Bill
«There is a spectrum, from "clearly desirable behaviour," to "possibly dodgy behavior that still makes some sense," to "clearly undesirable behavior." We try to make the latter into warnings or, better, errors. But stuff that is in the middle category you don’t want to restrict unless there is a clear way to work around it.» Eric Lippert, May 14, 2008
|
|
|
|
|
|
I'm probably missing something here, but why do you want to reinvent the wheel?
No, there are no dictionaries in javascript <spit>, it's untyped afterall. But if you call them by the normally accepted name, associative array, you'll notice it's already built in, even in such a backwards language as javascript <spit>.
More info here: JavaScript <spit>- Objects as associative arrays[^]
|
|
|
|
|
I know objects are implemented as associative arrays so JavaScript kind of has a Dictionary.
JavaScript also has an array that sort of acts like a list (but "add" is called "push", it's also a queue and a stack, it doesn't even have a decent "contains" function (it does in newer browsers, but it's called "includes", because that's what it's called everywhere else, right?), etc.).
So, just like everything else in JavaScript, arrays and associative arrays suck, that's why I'm making my own
|
|
|
|
|
Ok fair enough, I suspected I was missing out something.
But I would assume the builtin funtions are a bit better optimized than anything you can implement yourself, so I would probably just try to add the missing functionality to the builtin arrays rather than starting over from the beginning.
|
|
|
|
|
"Premature optimization is the root of all evil" - Donald Knuth
|
|
|
|
|
Donald Knuth didn't know about javascript <spit> then.
|
|
|
|
|
I'll be sure to test for performance then
|
|
|
|
|
Hi Jorgen,
I doubt Donald Knuth ... in his worst nightmare ... could have ever imagined an enterprise with the scope of the WWW that would converge on using a lingua franca of a screwed up scripting tool, named after a language it had nothing to do with, stretched like a yogic contortionist to fit containers it never belonged in, patched-up with all kinds of graphic/widget extension junk, super-glued together with a half-assed mark-up language, duct-taped to a half-assed meta-mark-up style language, with all the flaws of Visual Basic ...
becoming a standard because it was the only "neutral ground" the major power$-that-be who ate the web, and are now digesting it into cash, could, by default, mutually tolerate.
Do I need to say that I don't like JavaEcmaScript ?
cheers, Bill
«There is a spectrum, from "clearly desirable behaviour," to "possibly dodgy behavior that still makes some sense," to "clearly undesirable behavior." We try to make the latter into warnings or, better, errors. But stuff that is in the middle category you don’t want to restrict unless there is a clear way to work around it.» Eric Lippert, May 14, 2008
|
|
|
|
|
|