> On Sun, Mar 03, 2002, [EMAIL PROTECTED] wrote:
> > I was looking at that the other day too. It can easily be changed to only choose 
> > autogenerate if the doc_file=PLUCKERDIR/channels/<CHANNEL NAME>/<CHANNEL 
> > NAME> 
> 
> Why do you have to change the setting? If I as a user make a choice
> that would make the name the same as it would have been if
> autogenerated then it won't add anything but confusion if the setting
> is changed the next time I visit the destination dialog. I (the user)
> decide what the setting should be, not the program.

I agree absolutely. However, both the code size and total number of config keys has 
been kept minimal. Because of this some controls will be dumb in regards to 
close/reopen state. That is, if you type something into the 
Channel Dialog > Output options > "Specify a category in viewer" textctrl, 
and then uncheck the box, the textctrl greys out but your entered text remains. Close 
the dialog and reopen it, and the textctrl is now greyed out and blank. 
Ditto for typing a file:// protocol into the "A website URL" textctrl: close it, 
reopen and 
the key value, starting with a file:// is now moved down to the "A file" textctrl.
The reason is that no key was kept in the config to store all these extra things, as 
the 
code would get too slow and unmaintainable, and the pluckerrc file for each channel 
would be a nightmare to edit or dealt with. 
There is a guess heuristic built into the desktop to keep things compatible with the 
rest of the Plucker toolchain while at the same time not being unmaintainable, slow, 
bloated, or flooding the configs with extra keys. Patches are welcomed if you think it 
should be done differently.

Thus for the specify filename control, I do think that if the 

doc_file=PLUCKERDIR/channels/<CHANNEL NAME>/<CHANNEL NAME> then the 

autogenerate filename radiobutton should select. Dumping more keys into the config 
seems suboptimal. On dialog startup, however, the label can be updated to inform you 
where it is going, such as if loaded your channel called "test", you would see a label 
called:
Autogenerate the filename [ plucker:/channels/test/test ]
or could expand it to full path
Autogenerate the filename [ /whateverdirectory/plucker/channels/test/test ]

There are 2 other main cases:
doc_file is empty
doc_file is some other absolute or relative path 

Open to the implementation that you suggest for these, the 3rd case is pretty 
straightforward. I think that doc_file=<CHANNEL NAME> alone should go in with 
some other absolute or relative path.

> > Creation of a new channel via GUI puts creates a new channels 
> > doc_file=PLUCKERDIR/channels/<CHANNEL NAME>/<CHANNEL NAME> 
> > so they are fine that way. Channels that are created and manipulated entirely by 
>GUI 
> > are fine.
> 
> Only if you use the autogenerated name. Otherwise it will end up in
> either PLUCKERDIR or at the location given by a full path.

Once you override autogenerate, then things get more complex for handling the cases, 
and I'd rather just let people enter anything and they can deal with the results. If 
in a 
channel section of test, one specified the doc_file key="overridetest", then the 
current 
planned behaviour is going to send that to pluckerdir currently.Entering a  
docfile=channels/test/overridetest would make an overidetest.pdb in the 
channesl/test/overridetest.

I am just not understanding what behaviour that you desire. Just tell me how you want 
the each of the cases
handled of what you enter, and it can be implemented.

Another option would be to just remove the "Specify filename" option entirely and 
replace it with an small icon of a despot :-)

Another option would be to add more UI radiobutton elements to allow more of the 
cases to be displayed, demonstating and describing what prefix is added to the file.

> > I guess would be the no doc_file key exists would also need to be
> > handled in some way. What do you suggest there?
> 
> No idea, since that sentence didn't make sense to me. Can you repeat
> it in English, please ;-)

Err.. Let me remove some words from that one... 
I guess the no doc_file key exists would also need to be
handled in some way. What do you suggest there?

> > Off the top of my head, the flow of the current way is to check somewhere in the 
> > startup to see if a NEW_CHANNEL_TEMPLATE section / subdir exists, and if not 
> > then create it.
> 
> Yes it does that, but it also *always* append '_' making it always
> fail when looking for NEW_CHANNEL_TEMPLATE.

The template section was in need of being pulled away from add channel behaviour 
entirely. Did them this afternoon. 
> > It's probably better to just fix this bug in the toolkit than to
> > hack around it.
> 
> I don't know where the bug is, but when I compile the desktop code
> with debug info I get three assertions when I start the program 
> ("invalid index in wxListBase::Item" in src/common/list.cpp). They
> happen when the main_dialog ctor calls AttachUnknownControl for
> main_dialog_channels_tab_main_listctr.

Thanks. Will take a look. 

Best wishes,
Robert

Reply via email to