|
This is an app question
But no programming is involved, I am wondering about best behavior... and tentatively put my question in the lounge. Please let me know if another forum that is more appropriate
I am working at home on a personal app (that I hope to publish) which is sort of, but not quite, a vector drawing program.
I just reached the part where I got curves and shapes and I want to provide some selection / node editing functionality.
I want to implement a bunch of operations (below) that I hope to have one 1 tool (many tools might also be confusing, I think), here they are:
- split a segment in the middle (1 segment becomes 2)
- add a point in the middle (a segment become a spline, a spline become a quadratic bezier... name might be wrong but, basically going up in the 2,3,4 number of control points of bezier segment)
- move selected (control?) points
- delete point (control point or endpoint, i.e. merging 2 bezier)
now the user experience part (the tricky part)
- moving is easy: click on point / handle, move all that is selected
- split point vs increase order: I was think to use normal vs CTRL click in the middle
- CTRL delete on segment (outside middle) delete
- toggle point selection: CTRL click
- delete point: CTRL click
(Remark: I am edging toward ALT for point to curve increase order, and delete.. all sounds very different but there is UI feedback)
see.. CTRL does too much, particularly when clicking on a point it does selection toggle and delete.
so I thought maybe I use CTRL and ALT (or SHIFT).. but that become rather complicated... doesn't it?
also if deleting a point between 2 bezier segment (4 and 4 control point), what to do? Bezier segment have a maximum of 4 control point (all my home made math tool stops 4 control points, and UI primitive do as well)?
Anyway if anyone has any idea about smooth user editing experience, let me know!
EDIT:
I think I got it, what do you think?
operations grouped by target:
empty area:
- normal click + drag: selection rect
- SHFT + click + drag => union selection rect
- CTRL + click + drag => toggle selection rect
- ALT + click + drag => un-selection rect
unselected control point:
- click: select and move selection on drag
- CTRL/SHIFT + click: select (and move selection on drag?)
- ALT + click: delete
selected control point:
- click: drag/move
- CTRL: unselect
- ALT + click: delete (only on inside control point, not on start/end)(on /start/end merge 2 consecutive bezier curve into 1 segment)
curve:
- click: select all control points
- ALT + click: delete segment
- CTRL + SHIFT click: add control points if possible (i.e. increase order: 2,3,4 control points)
- CTRL + click: split in 2 in the middle (i.e. add point)
modified 30-Jan-19 1:18am.
|
|
|
|
|
I wouldn't use Alt+Click to delete (unless you're happy with a lot of wear and tear on the Ctrl and Z keys).
I'd either leave it unset, or set it as unselect.
Always be very specific with deletion, because it's a destructive action -- use the Delete key, every time.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
Mmm... you have a good point here..
btw CTRL+Z work quite well so I am not to worry...
But... I can't delete segment that well...
For example if I delete /\ below, I don't delete the line in between, I just create 1 large segment, as shown below
Before
_____
_____/ \____
After
_________________
so I need a way to delete a segment.
arguable I can with the erase tool (I got a vector graphic erasing tool ) but you have to change tool, cumbersome...
right hand on the keyboard, left hand close to CTRL/ALT/SH*T.. DELETE is far away!
What would you suggest to delete a segment.
Clarification: I can select point node. When selection is satisfactory I can click Delete.
But I can't select a segment, hence I can't delete it.... (other than by clicking on it, or using erase tool)
|
|
|
|
|
You could maybe put it in a context menu, as long as the word "Delete" ("Delete Segment", maybe?) makes it very clear what the user is about to do.
Preventing unwanted destructive actions makes customers swear less -- and when they swear, they blame you.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
|
Well.. one will have to ALT+click. One will easily learn the power of ALT!
And also... CTRL+Z always works well. This is the best working functionality so far! ^_^
But yeah.. context menu seems to a be winner...
Though a "custom context menu".
Default context menu animation is slow and intrusive (probably gonna use a fast fade in) and the general UI not friend to edit a segment.
It will be more like a "context something tool"
|
|
|
|
|
In your example you are deleting four nodes leaving only the start and end nodes, so I would expect to select the four nodes (left click) and then delete. You can't delete a single segment without some mechanism for re-connecting the remaining segments (or leaving 2 unconnected lines), but you can delete a single node to merge 2 segments, hence selecting nodes is more functional than selecting segments. Only use delete key or right click context menu. Don't invent new ways of interacting when the existing ways work just fine. If you have to explain your UI then the UI isn't right.
|
|
|
|
|
One thing to consider is using a right-click to pop up a menu where they can select all of these options, so the application is usable without using the keyboard, or at least minimal keyboard use.
Bezier curves can have as many control points as you want, if you draw them yourself (let me know if you need help with this.) As you say Windows limits you to 4 control points.
|
|
|
|
|
- About context menu idea:
I find right click context menu a but less straight forward..
But I find my click option (so far) confusing though... mm.. who knows...
You remind me I was tempted (at one stage) to have something like Word, the floating format panel that appears after select. But I forgot about it as I realised the panel disappear when you go away to never come back...
Mmm.. maybe I should do just that.. a context menu.. that automatically appear when mouse is close to line. It should just fade in though.. context menu animation seem a bit slow and.. intrusive.
It would be small since it would be 3 short image that describe: split in 2, delete segment, add bezier control point
- About Bezier Curve:
I am using WPF PathGeometry for drawing here. It only goes to Bezier fragment with 4 control point (start, ctrl pt1, ctrl pt2, end).
At any rate it would add little benefit, I am not interested in perfectly fitting and accurate curve but in quick and dirty editing. The idea is to create table top pen and paper RPG map as quickly as possible. Faster that with real pen and paper.
|
|
|
|
|
Just sent three E-Mails.
They all bounced in less than five minutes.
One was within 60 seconds.
They were all legitimate, the other guys wrote me first, and I responded.
My suspicion: My host is allowing the wrong people to rent from him, and my reputation goes out the window with probably a thousand other normal folks.
Suggestions welcome.
|
|
|
|
|
hang in there.... tech support will call soon (it's still really early morning in South Asia)
just give them access to your PC when they ask for it, it'll go much faster that way.
|
|
|
|
|
Use a different email server? Gmail, Yahoo Mail etc.
|
|
|
|
|
I use a couple of hundred different forwarding addresses
(and corresponding identities) to annoy spammers, and it
appears to have been effective; I will estimate that 99%
effective; though I don't have a scientific metric I can
use to verify that. Google and yahoo (great E-Mail, both
of them) wouldn't like my idea of two hundred addresses.
(And who can blame them ?)
Anyway, first time I tried E-Mail tonight, it bounced in
one minute or less.
I'm not well familiar with E-Mail structure. Does E-Mail
contain info about the host in the headers ? I am living
in a hotel room for a few more weeks, and I am wondering
if there is a spammer running a bot on the ISP providing
service here.
At any rate, I am screwed for now.
|
|
|
|
|
Maybe the distance to the the receiver was more than 500 miles ... The case of the 500-mile email[^]
We have a saying in Norwegian: If it isn't true, at least it is a d**m good lie. But I actually believe in this story - the remarks in the FAQ (link at top of the post) answers to so many of the critical questions that it sounds like not something made up.
For the more serious part - your problems could be related to one we had:
One of our customers where kind enough to inform us that when they answered our mails by a "Reply to all", one of our recipients bounced. We had introduced an internal distribution list, CC-ing outgoing mail to that list. The list was strictly internal, so to keep it from being spammed, the list email address was not exposed externally; the mail server rejected all incoming mail from external sources to this list - including when someone replied to our emails by "Reply to all". We decided to open the list for external mail, and haven't seen a spam problem yet, but we may have to find other solutions if we see spam traffic building up.
|
|
|
|
|
When you climb 4000 ft above sea level to one of the cabins of the Norwegian hiker's assocation (DNT) to visit this cabin:
Rabothytta[^]
then you know it is Winter, in the captialized version!
The photographer tells that he managed to hack through the ice on the back side.
|
|
|
|
|
Is it coming, though?!
|
|
|
|
|
I just looked out the window: It's here.
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Ha! those northy!
South hemisphere here!
|
|
|
|
|
So ... bush fires, droughts, flies, and spiders that are out to kill you?
I'll live with snow, thanks!
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
And episodes of "Peppa Pig" being banned because the theme of the episode was "spiders are very small and they can't hurt you".
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Seriously? I guess that makes sense over there ... mind you, my neighbour was bitten by a spider and had to take months of work because her arm didn't work - some of them in the UK are dangerous: e.g. the False Widow. But that doesn't use it's net as a trampoline to try and catch Drop Bears like some of theirs ...
Sent from my Amstrad PC 1640
Never throw anything away, Griff
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
Try restarting your window. That clears the memory cache, so it'll take a fresh look.
I wanna be a eunuchs developer! Pass me a bread knife!
|
|
|
|
|
"he managed to hack through the ice on the back side"
|
|
|
|
|
I have Visual Studio 2019 installed on my machine. I just built a C++ desktop app from template.
I will continue the shocking part of this story but first a little history...
Around 1993
Long ago (1993) I started learning C++.
The developers in my group at that time were writing a large program using Visual Studio 1,2,3, etc. and developing on the Windows SDK -- SDK style programming which was basically C wrapped up in Microsoft's way of doing things.
MFC : I Thought It Was Fantastic
Okay, but at that same time a fantastic thing was born: MFC (Microsoft Foundation Classes)
This was true C++ wrappers around the API calls. It was quite fantastic and I began to learn it.
It was kind of like C# before C# was released.
I was stuck between these amazing devs who knew Win API SDK style programming and the MFC (which used true OOP). The generation in front of me wanted little to do with these "unnecessary wrappers around the API"
But I continued into MFC.
Finally, around 1999 Microsoft announces C# and I am angry. Java-like? Throw away this investment into the MFC? Well, it'll be okay, because people will come to their senses and see that MFC is already doing all this stuff they're only promising with C#. Yeah, that's the ticket!
I Jump On Board C#
Finally, I jump on board the C# train and it becomes a rocket. It's the Windows API wrapped in OOP. There are missing things (as the .NET libraries become mature) and I understand how to get to those with pinvoke which is based upon my experience with (yes, Visual Basic) and knowing the Win API from MFC, etc.
We Now Return To My Original Shock
So, now, it's like 20 years later and I build a desktop app from the Visual C++ template and what do I see? Original Windows API stuff!!!!
It's the unwrapped, unvarnished message loop!!!
while (GetMessage(&msg, nullptr, 0, 0))
{
if (!TranslateAccelerator(msg.hwnd, hAccelTable, &msg))
{
TranslateMessage(&msg);
DispatchMessage(&msg);
}
}
It's the old RegisterClass (not related to OOP and classes but related to WNDCLASS).
ATOM MyRegisterClass(HINSTANCE hInstance)
{
WNDCLASSEXW wcex;
wcex.cbSize = sizeof(WNDCLASSEX);
wcex.style = CS_HREDRAW | CS_VREDRAW;
wcex.lpfnWndProc = WndProc;
wcex.cbClsExtra = 0;
wcex.cbWndExtra = 0;
wcex.hInstance = hInstance;
wcex.hIcon = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_FIRSTC));
wcex.hCursor = LoadCursor(nullptr, IDC_ARROW);
wcex.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
wcex.lpszMenuName = MAKEINTRESOURCEW(IDC_FIRSTC);
wcex.lpszClassName = szWindowClass;
wcex.hIconSm = LoadIcon(wcex.hInstance, MAKEINTRESOURCE(IDI_SMALL));
return RegisterClassExW(&wcex);
}
And where is MFC that wrapped all of this up in nice C++ OOP?
I don't know.
This is MODREN TECHKNOWLEDGY!!! The old has come back to haunt us!!!
This is 1993 tech, okay?
And I know lots of greybeards are going to chime in, "This is the special domain of geniuses and you just don't understand." I know. I know. But the MFC was so nice.
I blame C# for this travesty. Sorry...I'll crawl back over to the C# projects.
EDIT - MFC Desktop Template Gone from 2019?
I believe the Visual Studio template for building desktop apps with MFC is actually removed from Visual Studio 2019.
Here's the explanation of how to get to it in 2017 -- similar to previous versions of VStudio:
Windows desktop development with C++ in Visual Studio | Visual C++ Team Blog[^]
However, if you attempt to find that in 2019 you get no results (shown in following snapshots):
https://i.stack.imgur.com/ZRG43.png[^]
https://i.stack.imgur.com/REriZ.png[^]
The Desktop project template does not allow you to choose the MFC option in 2019.
It may be gone. Interesting.
It could be because it is 2019 Preview 2 and not in yet, but not sure.
EDIT 2 - Found Out How To Get MFC to Install
Ok, I found it way over on the right side in the installer.
There is one checkbox you have to select way over on the right.
That is independent from the item you can see on the left which says Desktop Development with MFC -- which I had already installed. Really terrible. You can see it at:
https://i.stack.imgur.com/ue4FM.png[^]
modified 30-Jan-19 10:03am.
|
|
|
|
|
Build the windows app from MFC rather than the win32 API.
Anyway, things change even slower in the kernel.
|
|
|
|
|