The Filetypes-folder and a few other questions.
  • Just looking around
    Desolator
    Posts: 17 from 2003/8/7
    From: Lund, Sweden
    With the latest CVS we saw the filetypes folder being introduced with scripts etc. So far I've only got this to work in some sort of half-assed way. ;)

    I can get Mplayer to play AVI's etc without any problem, but when it comes to images and MP3's I'm totally stuck. (I use the scripts that came with Gunne's compiled Ambient over at pegasos.org)

    When I click a JPEG, Showgirls come up but its in a tiny window in the middle of the screen which I can't resize. If I doubleclick it to get fullscreen the picture extends all the way to the top and bottom of the screen but its just about 2 inches wide. Not fullscreen. Can I change this somehow?

    And when it comes to MP3's it opens AmiNetRadio just fine but then the Arexx script crashes with an error on line 15.

    also I have these questions:

    Is there a way to make every MP3 file on the whole system to have the same Icon? As it is now, I have to select each one, open the info window and drag an icon to it so it changes. This goes for drawers too.

    and finally.. when I edit a text in an editor and save it, sometimes the folder the text was saved in pops up. Not just ONE window but several. This also happens when I unpack a LhA file by doubleclicking it and pointing it at RAM: but if I do it from the CLI then it works just fine, no annoying windows that pop up.

    And yes, I'm a new MorphOS user. Loving it so far, but it's quite different to the AmigaOS I'm used to. :)

    [ Edited by Desolator on 2006/1/10 14:01 ]
  • »10.01.06 - 13:00
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    winterhunter
    Posts: 204 from 2005/10/13
    From: PACA, France
    Quote:


    Desolator wrote:

    Is there a way to make every MP3 file on the whole system to have the same Icon? As it is now, I have to select each one, open the info window and drag an icon to it so it changes. This goes for drawers too.
    [ Edited by Desolator on 2006/1/10 14:01 ]


    That one I can answer: in sys:prefs/???env (I'm at work and don't remember the exact name) you must put a file named def_MP3.icon (with the image you want to use). It then becomes the "standard" icon for MP3s.
    After that, you either reboot or copy the file also to RAM:prefs/...

    The folders are:
    SYS:prefs/env-archive/sys
    RAM:env/sys

    [ Edited by winterhunter on 2006/1/10 21:26 ]
  • »10.01.06 - 13:25
    Profile Visit Website
  • Just looking around
    Desolator
    Posts: 17 from 2003/8/7
    From: Lund, Sweden
    thanks! that worked like a charm. :)

    Hope somone answer the other questions so it will be a perfect morphos experience.
  • »10.01.06 - 19:26
    Profile
  • Moderator
    gunne
    Posts: 441 from 2003/2/26
    From: Sweden
    Hi,

    Didn't see this thread at first.

    # Showgirls.

    If you have a file; showgirls.1.prefs in Envarc:MUI/ (and in ENV:MUI/)

    Then delete this file, and you can resize the showgirls-window in window mode afterwards.

    As for def-icons, this was answered by winterhunter.

    In the new Ambient you can also set the def-icon directory to any drawer on your harddrive, which means def-icons wont be copied to ram:, (as they will be when they belongs to the Envarc: directory which is copied to ENV: during startup). Saves some memory, and speeds up booting as less things is copied to ram: during startup.

    You do change path in 'Ambient Settings/Miscellaneous - Path to default icons'

    My output below:


    Mos:Prefs/deficons> list
    def_CON.info 8448 ----rwed 27-Mar-03 07:01:27
    def_disk.info 6934 ----rwed 07-Mar-04 01:11:40
    def_drawer.info 1685 ----rwed 08-Sep-80 21:15:04
    def_RAMdisk.info 5792 ----rwed 05-Oct-05 17:41:44
    def_SDL.info 5162 ----rwed 28-Dec-04 05:58:44
    def_tool.info 5320 ----rwed 27-Mar-03 07:01:27
    def_Miamionline.info 10658 ----rwed 10-Oct-05 21:05:00
    def_avi.info 8924 ----rwed 05-Sep-02 00:00:00
    def_mov.info 9021 ----rwed 05-Sep-02 00:00:00
    def_mpg.info 9034 ----rwed 05-Sep-02 00:00:00
    def_bmp.info 6785 ----rwed 09-Sep-02 00:00:00
    def_pic.info 7280 ----rwed 09-Sep-02 00:00:00
    def_gif.info 6696 ----rwed 09-Sep-02 00:00:00
    def_iff.info 6637 ----rwed 09-Sep-02 00:00:00
    def_jpg.info 6915 ----rwed 09-Sep-02 00:00:00
    def_pcx.info 6748 ----rwed 09-Sep-02 00:00:00
    def_pict.info 7399 ----rwed 09-Sep-02 00:00:00
    def_png.info 7132 ----rwed 09-Sep-02 00:00:00
    def_tga.info 6580 ----rwed 09-Sep-02 00:00:00
    def_tif.info 7228 ----rwed 09-Sep-02 00:00:00
    def_aiff.info 7379 ----rwed 06-Sep-02 00:00:00
    def_mp3.info 7418 ----rwed 06-Sep-02 00:00:00
    def_ogg.info 7430 ----rwed 06-Sep-02 00:00:00
    def_wave.info 7431 ----rwed 06-Sep-02 00:00:00
    def_doc.info 4977 ----rwed 29-Aug-80 19:38:00
    def_pdf.info 8400 ----rwed 29-Aug-80 19:38:00
    def_txt.info 5241 ----rwed 29-Aug-80 19:38:00
    def_html.info 9812 ----rw-d 07-Aug-09 09:00:26
    28 files - 198466 bytes used
    Mos:Prefs/deficons>


    As I see you are from Sweden, this is also explained in the Ambientguide (as well as many other things), available in swedish from pegasos.org.

    This with several window popping up, I have no idea as I haven't seen this myself.

    Gunne

    [ Edited by gunne on 2006/1/16 19:21 ]
    Best wishes, Gunne
  • »15.01.06 - 15:24
    Profile Visit Website
  • Moderator
    gunne
    Posts: 441 from 2003/2/26
    From: Sweden
    Hi again,

    > And when it comes to MP3's it opens AmiNetRadio just fine but then the Arexx script crashes with an error on line 15.

    ----

    I made a slightly change tho the Arexx-script, ANR.rexx, which should wait for the port and not cause this error message if ANR not is already running.

    Try this instead.


    /*
    ** $VER: ANR-Script 1.1 (01.15.2006)
    */


    ANRPATH = 'Work:Extras/AmiNetRadio4/AminetRadio'


    parse arg mode' 'url
    options results

    IF ~show('P','AMINETRADIO.1') then address command 'WBRun 'ANRPATH
    do
    if ~show('P','AMINETRADIO.1') then address command 'waitforport AMINETRADIO.1'
    end

    address 'AMINETRADIO.1' 'PLAY NAME='url


    You need to change ANRPATH to where your AmiNetRadio is located.

    Gunne

    [ Edited by gunne on 2006/1/16 3:07 ]
    Best wishes, Gunne
  • »15.01.06 - 17:43
    Profile Visit Website
  • Just looking around
    Desolator
    Posts: 17 from 2003/8/7
    From: Lund, Sweden
    Thanks! Now everything works as expected. :)
  • »16.01.06 - 09:23
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    GK_LKA
    Posts: 481 from 2004/3/28
    From: Hungary
    Maybe not the perfect topic, but I didn't want to open a new for this, sorry...

    Well, the basic conception is - if I'm not wrong - that the Match parts of the filetypes are stored globally in the recognition.db as part of the system, and the Action parts are stored in different files, which can the users edit for their needs.

    The thing which joins the two files is the mime type, isn't?

    Well, if I create e.g. a JPEG file into the sys:prefs/ambient/filetypes/image/jpeg with the content:

    AMTD
    1
    Name JPEG Image file
    Type image/jpeg
    Action
    ...
    End
    ...
    End

    The filetype at next boot is recognized as "Datatype". What's wrong? Is it an Ambient bug, or am I stupid? :)
    [ GK / LKA Team ]
  • »10.05.06 - 15:08
    Profile Visit Website
  • MorphOS Developer
    kiero
    Posts: 129 from 2003/2/28
    jes, it's mimetype that connects them. and yes, it does work:) show full descriptor. maybe you made some mistake.
    oh, and you don't need a reboot for changes to take effect anymore.


    [ Edited by kiero on 2006/5/10 15:13 ]
  • »10.05.06 - 16:09
    Profile Visit Website
  • Paladin of the Pegasos
    Paladin of the Pegasos
    tokai
    Posts: 1289 from 2003/2/25
    From: binaryriot
    @gk_lka:

    what u posted here looks just right. You could ommit the "Name" though.

    just:

    AMTD
    1
    Type image/jpeg
    Action
    ...
    End
    End

    make sure u have all "End" etc. properly, else it will fail.

    regards,
    tokai
  • »10.05.06 - 17:13
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    GK_LKA
    Posts: 481 from 2004/3/28
    From: Hungary
    Khm, so I think that you are right, and the problem is with my types. I deleted all of them, then created only the following file in sys:prefs/ambient/filetypes/lha:

    Code:

    AMTD
    1
    Name LHa Archive
    Type application/lha
    Action
    Name Open with Voodoo-X
    Event DoubleClick
    Command AMIGADOS RUN >NIL: $pathvoodoox %sp
    End
    Action
    Name List archive contents with lha
    Event Menu
    Command AMIGADOS DELETE T:LHA.out QUIET >NIL:
    Command AMIGADOS lha l %sp >T:lha.out
    Command AMIGADOS RUN >NIL: $pathmore T:LHA.out >NIL:
    End
    Action
    Name Extract to Ram with lha
    Event Menu
    Command AMIGADOS RUN >NIL: lha x %sp ram:
    Command INTERNAL LoadURI ram:
    End
    Action
    Name Extract to... with lha
    Event Menu
    Command AMIGADOS RUN >NIL: lha x %sp %D
    Command INTERNAL LoadURI %D
    Flag cd destination
    End
    Action
    Name Move to Archives
    Event Menu
    Command AMIGADOS RUN >NIL: move %sp $patharchives FORCE
    End
    End


    The recognition.db is in sys:prefs/ambient/filetypes, and I have modified only the global actions part (added Archive, Open with and Filex).

    These are my settings, and it doesn't work. Ambient doesn't recognize lha files, they are only "Datatype" types.

    I have the latest 08.05.2006 build.


    [ Edited by GK_LKA on 2006/5/11 12:22 ]
    [ GK / LKA Team ]
  • »11.05.06 - 11:49
    Profile Visit Website
  • Paladin of the Pegasos
    Paladin of the Pegasos
    jcmarcos
    Posts: 1178 from 2003/3/13
    From: Pinto, Madrid ...
    I'm intrigued by this:

    Code:
    Action
    Name Extract to... with lha
    Event Menu
    Command AMIGADOS RUN >NIL: lha x %sp %D
    Command INTERNAL LoadURI %D
    Flag cd destination
    End


    So, this action is to extract to a given path? If so, how does ambient ask the user for that path, that I understand is stored in that "%D" that is passed later to LHA?
  • »11.05.06 - 12:23
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    GK_LKA
    Posts: 481 from 2004/3/28
    From: Hungary
    To tell you the turth, I don't know, I've found it in Mario's fileytype pack found on the daily builds site.

    The other thing I noticed is, that even the jpeg or gif files are recognized. Hm... Is the path of recognition.db correct?
    [ GK / LKA Team ]
  • »11.05.06 - 12:27
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    koan
    Posts: 303 from 2005/11/21
    From: UK
    I found a problem with PNG recognition, the (previously working) PNG filetype stopped working. I don't know if this is something to do with Ambient confused about what is an icon or not. I'm using the CVS build from about 1 or 2 weeks ago.

    I get problems with multiple icon selection by drawing a box: the box doesn't appear all the time. Also copying files between large directories is very slow. These are the joys of CVS builds.

    koan
  • »11.05.06 - 12:59
    Profile
  • MorphOS Developer
    kiero
    Posts: 129 from 2003/2/28
    > The other thing I noticed is, that even the jpeg or gif files are recognized. Hm... Is the path of recognition.db correct?

    NO! This file HAVE to be in ambient's directory.
  • »11.05.06 - 16:10
    Profile Visit Website
  • MorphOS Developer
    kiero
    Posts: 129 from 2003/2/28
    png problem was fixed some time ago.
  • »11.05.06 - 16:29
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    GK_LKA
    Posts: 481 from 2004/3/28
    From: Hungary
    Hm.. Thanks, I moved recognition.db from sys:prefs/ambient to mossys:ambient, and merging now works fine. Thanks! (I just don't understand why the global actions part was readed from the old place too...)


    [ Edited by GK_LKA on 2006/5/11 19:21 ]
    [ GK / LKA Team ]
  • »11.05.06 - 16:49
    Profile Visit Website
  • MorphOS Developer
    kiero
    Posts: 129 from 2003/2/28
    you don't have to understand how things work to use them.
  • »11.05.06 - 20:05
    Profile Visit Website
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    C64Days
    Posts: 103 from 2006/2/27
    From: Italy
    Further changes took place in the latest Ambient nightly builds, now there are subdirectories names after mimetypes classes in

    SYS:Prefs/Ambient/Filetypes/

    that are "application", "audio", "image", etc

    and Def Icons are matched accordingly, thus, "lha.info" (no more with
    "Def_" prefix) will go to SYS:Prefs/Ambient/Filetypes/application/
    and so on.

    My question is, where are the devices default icons expected to be
    placed? (Ram Disk, UMSD, CD0, etc) and how should they be
    renamed to? Thanks!
  • »11.05.06 - 20:28
    Profile
  • MorphOS Developer
    kiero
    Posts: 129 from 2003/2/28
    devices still use old system, so they take icons from def_ files.
  • »11.05.06 - 20:32
    Profile Visit Website
  • Paladin of the Pegasos
    Paladin of the Pegasos
    Acill
    Posts: 1914 from 2003/10/19
    From: Port Hueneme, Ca.
    All this def icons stuff got me wanting to clean my system up now. So I can remove all the DEF_xxx files from ENV and place them into aq folder i want and in prefs tell it where that folder is? I have 1.5GB of RAM so its not that big of a deal, but I like to have my system easy to read through and folders organized as much as I can.

    Can someone using the new system post a screen grab of how its looks?

    [ Edited by Acill on 2006/5/11 17:51 ]
    Powermac Dual 2.0 GHZ G5 PCI-X (Registration #1894)
    Powerbook 1.67GHZ
    Powermac Dual 2.0 GHZ G5 PCIE (Registration #6130)
    A4000T CSPPC, Mediator
    Need Repairs, upgrades or a recap in the USA? Visit my website at http://www.acill.com
  • »12.05.06 - 02:50
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    GK_LKA
    Posts: 481 from 2004/3/28
    From: Hungary
    @Acill:

    http://www.lka.hu/home/gk/pic/ambientshot.png

    @kiero:

    I've moved recognition.db into mossys:ambient, recreated all of my filetypes, and now I have only 2 questions:

    1) Reloading filetypes doesn't work for me. To exactly say, I've noticed, that sometimes I can see the changes, but usually don't. Or it seems like it is reloaded in every hour, or something similar.

    2) x-morphos-global-action doesn't work from the new recognition.db location, only from the old (sys:prefs/ambient/filetypes/recognition.db).
    [ GK / LKA Team ]
  • »12.05.06 - 10:20
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    koan
    Posts: 303 from 2005/11/21
    From: UK
    I hope this is not going OT as the discussion is about Ambient issues.

    How can I make a duplicate copy of a file in Ambient in the same directory ? There is no option to rename the new file.

    I can't snapshot window position and size, or has this bug been fixed ?

    Some of my def_icons are standard AmigaOS icons. In file requesters they have no image; I suppose this is a MUI4 problem ? I don't have an app to convert standard icons to PNG.

    cheers

    koan
  • »12.05.06 - 11:45
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    GK_LKA
    Posts: 481 from 2004/3/28
    From: Hungary
    Quote:

    How can I make a duplicate copy of a file in Ambient in the same directory ? There is no option to rename the new file.


    No option to do that. You can copy it to Ram:, rename and move back to the drawer.


    Quote:

    I can't snapshot window position and size, or has this bug been fixed ?


    Snapshotting works for me in browser mode.

    Quote:

    Some of my def_icons are standard AmigaOS icons. In file requesters they have no image; I suppose this is a MUI4 problem ? I don't have an app to convert standard icons to PNG.


    I think this is a MUI4 problem, and has been or will be fixed.
    [ GK / LKA Team ]
  • »12.05.06 - 14:40
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    Toto
    Posts: 268 from 2003/4/20
    I had some trouble with filetypes, the deficons were not displayed. By adding 'PatternHint' to the filetype it works. Here's an example:

    AMTD
    1
    Type audio/mp3
    Match
    PatternHint #?.mp3
    Name #?.mp3
    End
    Action
    Name Play with AmiNetRadio
    Event DoubleClick
    Command AMIGADOS rx Sys:S/ANR.rexx url %sp
    End

    End

    Don't know if this is the correct way but it seems to work for me.
  • »13.05.06 - 13:28
    Profile
  • Paladin of the Pegasos
    Paladin of the Pegasos
    Acill
    Posts: 1914 from 2003/10/19
    From: Port Hueneme, Ca.
    I installed the latest nightly build but my icon types got all strange for unknown things. Before it showed the gear looking one found in envarc, the new ambient showed a saw and cutters icons for all unknown files. Where the heck is this at so I can start making new icons to show up on mp3 and pictures ect? I've restored my system back to Ambient 1.43 (12.03.2006) for now since its what I am used to looking at.
    Powermac Dual 2.0 GHZ G5 PCI-X (Registration #1894)
    Powerbook 1.67GHZ
    Powermac Dual 2.0 GHZ G5 PCIE (Registration #6130)
    A4000T CSPPC, Mediator
    Need Repairs, upgrades or a recap in the USA? Visit my website at http://www.acill.com
  • »13.05.06 - 14:49
    Profile Visit Website