1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

WAD Window title

Discussion in 'Support' started by vefatica, Jun 23, 2014.

  1. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    Below, TCC is showing me a window caption created by CMD.
    upload_2014-6-23_15-52-43.png
     
  2. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,854
    Likes Received:
    83
    WAD (it's behaved this way for at least 15+ years).

    Internal commands & externals called from recursive internals (like GLOBAL) always change the title. You just never see it unless you put a pause in the command. Changing this behavior will require a significant parser rewrite (and probably generate new, much more significant bugs) for no discernible benefit.

    If you disagree, you can add it to the suggestion forum and try to rally support from other users.
     
  3. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    Change it to what ... something inherited from some other app?

    I disagree. If I change the "GLOBAL PAUSE" to "GLOBAL ECHO foo", it makes no difference; the title still changes to a rock-solid "g:\tc16\tcc".

    And I can't believe it would be hard to change. I can change the the behavior so easily ...
    Code:
    TITLE /P %TITLEPROMPT & GLOBAL PAUSE
    With that I have a rock-solid title displaying what my title prompt describes. Compare this to the pic in my first post.
    upload_2014-6-24_1-7-46.png
     
  4. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,854
    Likes Received:
    83
    Change to the default title at startup (which, as I said, it has always done). If you don't like that, you've always had the option of changing it in your TCSTART.
     
  5. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,854
    Likes Received:
    83
    Great; I can eliminate 700 lines of special-case handling code. I'm sure nobody will miss it ...
     
  6. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    That would be nice. What did you have in mind? Using TITLE in TCSTART doesn't change the behavior.
     
  7. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,854
    Likes Received:
    83
    The only things I know of that could cause the kind of behavior you're seeing is if you have a TITLE or WINDOW command in your TCSTART.
     
  8. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    Well I don't. I tried it thinking that you had suggested it might fix things. It didn't and it's gone now. What happens when you do this with TITLEPROMPT set and UpdateTitle=No?

    Start\Run ... cmd ... then ... (you've got to wait for GLOBAL's second directory)

    upload_2014-6-29_0-12-29.png
     
  9. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    Here it again with no plugins and no tcstart.
    upload_2014-6-29_0-19-7.png
     
  10. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,854
    Likes Received:
    83
    Also, try running tcc with the trailing ".exe" (CMD doesn't fully expand the pathname).
     
  11. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    It doesn't matter. Whatever I specify on the CMD command line later shows up as the title when I execute GLOBAL.
    upload_2014-6-29_11-43-58.png
     
  12. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    To see this happen, you must have UpdateTitle=No.
     
  13. rconn

    rconn Administrator
    Staff Member

    Joined:
    May 14, 2008
    Messages:
    9,854
    Likes Received:
    83
    WAD. If the command argument does not end with "tcc.exe" (and yours doesn't), TCC will not switch to the "TCC Prompt" default argument. This is by design, as otherwise if you specified a title when starting TCC (i.e., via sui.lpTitle) it would always be overridden with a default title.

    In your failcase, you have to:

    1) Start TCC from CMD (an uncommon event)
    2) Don't use a fully-expanded filename for TCC (an uncommon event which can only happen when you deliberately do it while starting from CMD)
    3) Use TITLEPROMPT (an uncommon event)
    4) Set UpdateTitle=No (an uncommon event)
    5) Run an internal command like GLOBAL which calls the parser recursively (an uncommon event)
    6) Pause the internal command so you can see that the title has momentarily reverted to the original one (an uncommon event)

    Add all of those together, and you get a 1-in-15-years issue, which IMO at most falls into the "curious output" category, and is not a bug. Or worth a tiny fraction of the time spent talking about it.

    If you have an example of why this causes a real problem for you, please post that instead of this example.
     
  14. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,934
    Likes Received:
    30
    I use TITLEPROMPT and UpdateTitle=No for a reason. The only problem is that it's not doing what I want.

    You're right, it doesn't happen often. I only stumbled on it testing a GLOBAL routine in a TCC started by TASKENG.EXE.

    By the time it happens again (years perhaps) I will have forgotten about this discussion and probably complain again. :-)
     

Share This Page